sequences

Dominic Chorafakis XE41 ext. 9049 chorafad@access.bel.alcatel.be
Wed, 05 Nov 1997 14:35:59 +0100


Hi,

I am having great difficulties using sequences, and I was hoping
you maight give me some pointers.

I am creating the followiing object:

typedef sequence<char, 2000> Log;
interface Reader
{
  int ReadLog(out Log contents);
};

When compiled, this creates 2 typedef`s:
  Log
  Log_var


Then in the object implementation I do the following:
unsigned short Reader_impl::ReadLog(Log *& contents)
{
  contents->length(2);
  
  return 0;
}


On the client side, I'm not sure what I should invoke the method
with, but right now I have:

  Log     l;
  Log *&  p_l=&l;
  ...
  obj->ReadLog(p_l);
  ...

I have also tried:
  Log_var x;

  ...
  obj->ReadLog(x);
  ...

In both cases I keep getting segmentation faults on the server side.

Can you tell me what I am doing wrong, or if there is any information
on how to use sequences that I can read ?


Thanks,

Dom Chorafakis