Re: [PATCH/RFC v2 09/16] Read index-v5

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thomas Gummerer <t.gummerer@xxxxxxxxx> writes:

> On 08/08, Junio C Hamano wrote:
>> Thomas Gummerer <t.gummerer@xxxxxxxxx> writes:
>> ... 
>> After thinking about this, the ptr_add() macro might be the best
>> solution, even though I originally called it as a band-aid.  We know
>> mmap is a blob of memory, byte-offset of each component of which we
>> know about, so we can say
>> 
>>     name = ptr_add(mmap, *dir_offset);
>>     beginning = ptr_add(mmap, *dir_offset);
>> 
>> Hmmm..
>
> I start to think so too. Casting the mmap variable to "const char *"
> in the method call doesn't feel right to me, even though it would work.
> Unless there are any objections I'll use ptr_add in the next version.

Thanks for sanity checking my thinking.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]