[systemd-devel] [PATCH] shorten_uuid: use proper table size

Maciej Wereski m.wereski at partner.samsung.com
Wed Jun 11 01:03:20 PDT 2014


10.06.2014 at 19:20 Lennart Poettering <lennart at poettering.net> wrote:

> On Wed, 28.05.14 11:24, Maciej Wereski (m.wereski at partner.samsung.com)  
> wrote:
>
>> >When the function is called the buffer is filled with 36 chars, and we
>> >then strip the non-hex-chars, so that 34 chars result. But the function
>> >signature should still indicate that we need 36 chars initially..
>> >
>> >Lennart
>>
>> Well, i (< 36) is used for source and j (< 32) is used for destination.
>> After the loop destination[32] and destination[33] is set. Also
>> shorten_uuid() is used in two places, where id[34] is passed as
>> destination. So it looked for me like destination should be 34.
>
> I am an idiot and you are right... I now merged a patch that turns both
> strings into arrays and we speciy both sizes. I hope that cleans up the
> confusion. Please check!
>
> Lennart
>

Looks good, thanks.

regards,
-- 
Maciej Wereski
Samsung R&D Institute Poland
Samsung Electronics
m.wereski at partner.samsung.com


More information about the systemd-devel mailing list