libmsrpc for Samba 3

Chris Nicholls cnicholl at uoguelph.ca
Wed Jul 20 16:53:30 GMT 2005


>The initialize_operation() function can either set reasonable default values
>for each of the fields in "op" or set each parameter to an illegal value so
>that uninitialized fields can be caught in dcerpc_spoolss_OpenPrinter().
>
>Note that initialize_operation() specifically does NOT take parameters to fill
>in the structure.  That would, of course, eliminate the utility of the control
>block.  The function simply initialize all fields to reasonable defaults or
>illegal values.
>
>  
>
I considered something like that but it seems to me like using an 
initialize_operation() function is adding to complexity, there is a 
function just to prepare values for the second function call. Also, if 
something like this were used I would prefer a function like 
get_some_control_block() that would also allocate memory for such a 
structure and return it.  I guess in my mind that just seems like it 
accomplishes more.

What do you think?

Chris




More information about the samba-technical mailing list