Andreas Kloeckner wrote:
>
> Hi again Phil,
>
> the only difference between String_var and String_mgr i have been able
> to detect was that _mgr does not free anything in its destructor. in the
> comment above its declaration, you state it also initializes to an
> empty, rather than a null string, but this does not appear to be the
> case.
Err.. Yes - you're right. I need to check the spec to see if this is
what indeed is required.
> what exactly should be done differently? (since i'm integrating
> the _mgr with my _var templates, the only difference being made by a
> bool template parameter)
>
string_mgr definitely needs to not free anything in the destructor
(since CORBA_free on a variable length struct or sequence also deep
frees the contents). I'm not sure if it also needs to initialise to an
empty string - it depends on whether the C marshallers can cope with
NULL strings in sequences and structs.
Cheers,
Phil.
|