[SCM] Samba Shared Repository - branch master updated

Matthias Dieter Wallnöfer mdw at samba.org
Mon Mar 1 15:15:41 MST 2010


Simo,

metze pushed a bit an older version of this srvsvc "counters" patch 
which contained this error (I imagine it was the version from tridge's 
repo). I realised my fault after tridge fetched the branch and replaced 
the commit with a reworked version but only in my repo. Unfortunately 
not my latest version of this commit was taken for the push and so I had 
to create this "corrective" commit.

The changes are big (I agree) and I tried hard to get the types right. 
Unfortunately sometimes something can be missed. But exactly for this 
reason I ask for careful reviews. I rechecked the other commits in my 
"counters" and "counters2" branched and they should be okay at the 
moment. I would also like to thank abartlet, metze and tridge for 
reviewing and pushing some of them - I hope they continue to work also 
on the restant ones.

Regarding LDB: The structures were designed to deal with unsigned 
counters (consider num_attributes, num_values, num_entries and so on). 
For sure there was some reason to do so and not to choose the signed 
integers.
Okay, then why did people decide to use "signed" integer counters for 
enumerating those objects? Was it due to ignorance?
The patches might not have a real practical value but more a formal 
theoretical one.

Matthias

simo wrote:
> Matthias,
> this kind of problems is the reason why I am a bit uncomfortable with
> your patch to change in one sweeping move all internal ""counters"" in
> ldb to unsigned.
>
> Simo.
>
> On Mon, 2010-03-01 at 14:19 -0600, Matthias Dieter Wallnöfer wrote:
>    
>> The branch, master has been updated
>>         via  05bd8c1... s4:srvsvc RPC - revert one unsigned integer "i" back to signed
>>        from  cf12d45... testprogs: better usage text.
>>
>> http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
>>
>>
>> - Log -----------------------------------------------------------------
>> commit 05bd8c17be83057b9bcfe405fb29d27a794b9b40
>> Author: Matthias Dieter Wallnöfer<mwallnoefer at yahoo.de>
>> Date:   Mon Mar 1 21:11:39 2010 +0100
>>
>>      s4:srvsvc RPC - revert one unsigned integer "i" back to signed
>>
>>      This is needed since this particular "i" counts until "count" which itself is
>>      signed. "count" is set through a signed integer variable parameter from the
>>      "share_list_all" call.
>>
>> -----------------------------------------------------------------------
>>
>> Summary of changes:
>>   source4/rpc_server/srvsvc/dcesrv_srvsvc.c |    2 +-
>>   1 files changed, 1 insertions(+), 1 deletions(-)
>>
>>
>> Changeset truncated at 500 lines:
>>
>> diff --git a/source4/rpc_server/srvsvc/dcesrv_srvsvc.c b/source4/rpc_server/srvsvc/dcesrv_srvsvc.c
>> index 90edadb..d1e3f53 100644
>> --- a/source4/rpc_server/srvsvc/dcesrv_srvsvc.c
>> +++ b/source4/rpc_server/srvsvc/dcesrv_srvsvc.c
>> @@ -1384,7 +1384,7 @@ static WERROR dcesrv_srvsvc_NetShareCheck(struct dcesrv_call_state *dce_call, TA
>>   	char *device;
>>   	const char **names;
>>   	int count;
>> -	unsigned int i;
>> +	int i;
>>
>>   	*r->out.type = 0;
>>
>>
>>
>>      
>
>    



More information about the samba-technical mailing list