dlls/rpcrt4: fixed dead increments (llvm/clang)

Michael Stefaniuc mstefani at redhat.com
Wed Nov 19 16:43:04 CST 2008


Rob Shearman wrote:
> 2008/11/18 ricardo filipe <ricardo_barbano at hotmail.com>:
>> diff --git a/dlls/rpcrt4/rpc_transport.c b/dlls/rpcrt4/rpc_transport.c
>> index 3d66740..815ed64 100644
>> --- a/dlls/rpcrt4/rpc_transport.c
>> +++ b/dlls/rpcrt4/rpc_transport.c
>> @@ -479,7 +479,6 @@ static size_t rpcrt4_ncacn_np_get_top_of_tower(unsigned char *tower_data,
>>          memcpy(tower_data, networkaddr, networkaddr_size);
>>      else
>>          tower_data[0] = 0;
>> -    tower_data += networkaddr_size;
>>
>>      return size;
>>  }
>> @@ -692,7 +691,6 @@ static size_t rpcrt4_ncalrpc_get_top_of_tower(unsigned char *tower_data,
>>      pipe_floor->count_rhs = endpoint_size;
>>
>>      memcpy(tower_data, endpoint, endpoint_size);
>> -    tower_data += endpoint_size;
>>
>>      return size;
>>  }
> 
> These increments are intentional in case the code is copy and pasted
> and some more data is added to the end, so please don't remove them.
But those are dead code in the actual context and thus distract the 
reader. Shouldn't those be made comments instead?

bye
	michael



More information about the wine-devel mailing list