Code Generator Error for Variable Struture process ??



Title: Re: Code Generator Error for Variable Struture process ??
IDL File :
interface Four {
         /* Variable Array Type */
        typedef string AVar[2][3];
        AVar doAVar(in AVar inp, inout AVar inoutp, out AVar outp);
};
 
Generated skeleton Code :
void
_ORBIT_skel_Four_doAVar(POA_Four * _ORBIT_servant, GIOPRecvBuffer * _ORBIT_recv_buffer, CORBA_Environment * ev, Four_AVar_slice * (*_impl_doAVar) (PortableServer_Servant _servant, const Four_AVar inp, Four_AVar inoutp, Four_AVar_slice ** outp, CORBA_Environment * ev))
{
   Four_AVar_slice *_ORBIT_retval;
   Four_AVar inp;
   Four_AVar inoutp;  =====> Four_AVar *inoutp
 
Four_AVar_slice *outp;
   ¡¦¡¦.
   _ORBIT_retval = _impl_doAVar(_ORBIT_servant, inp, inoutp, &(outp), ev); ==> &(inoutp)
   
¡¦¡¦
  if (ev->_major == CORBA_NO_EXCEPTION)
 
   /*****************************************************************/
   /* Should not generated code ?segmentation fault occur */
   Four_AVar__free(&inoutp, NULL, CORBA_TRUE);
   /*****************************************************************/
  
      if (ev->_major == CORBA_NO_EXCEPTION)
         CORBA_free(outp);
}
 

I think that Four_AVar__free(&inoutp, ...) should not generate.
 
Your commenet is understand, but skeleton code not allocate for inoutp.
  and not pass over not inoutp pointer.
 
consequently, inplementation code not allocate memory for inoutp.
 
 
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]