Extension to Samba IDL.

Christopher R. Hertel crh at nts.umn.edu
Fri Jun 16 21:59:00 GMT 2000

On Jun 17,  7:47am, Luke Kenneth Casson Leighton wrote:
> Subject: Re: Extension to Samba IDL.
> On Sat, 17 Jun 2000, Christopher R. Hertel wrote:
> > I want bitfields.
> i need bitfields.  i need to do switch (bit 1) case 0: action case 1:
> actionother.
>-- End of excerpt from Luke Kenneth Casson Leighton

All I need is the go-ahead on what I proposed.

Some quick notes:

1) When using bitfields, we will have to be careful with alignment.  A two
   bit field with no following padding or alignment specified will shift the
   rest of the packet.  By default, I think that we should force any
   non-bitfield value to start on a byte boundary.
2) It's not good enough to simply mask a byte or word.  In the example I gave,
   you either have:

   [x|x|y|y|y|y|y|y] or
   [x|x|z|z|z|z|z|z|z|z|z|z|z|z|z|z] depending on the value of xx.

   So, if you parse it as a uint8 it might turn out that you needed a uint16,
   and vice versa.

Chris -)-----

Christopher R. Hertel -)-----                   University of Minnesota
crh at nts.umn.edu              Networking and Telecommunications Services

More information about the samba-technical mailing list