On 15.05.2018 15:42, Daniel Kiper wrote:
> On Mon, May 14, 2018 at 09:02:00PM +0200, Alexander Boettcher wrote:
>>    grub_relocator_chunk_t ch;
>> -  grub_uint32_t load_offset, load_size;
>> +  grub_uint32_t load_offset = 0, load_size;
>>    int i;
>> -  void *source;
>> +  void *source = NULL;
> 
> It seems to me that this change is not needed.
> I am thinking about "void *source = NULL;".
> 

The compiler complains if I remove the NULL assignment with:

 error: ‘source’ may be used uninitialized in this function
[-Werror=maybe-uninitialized]
             grub_memset ((grub_uint8_t *) source + load_offset +
phdr(i)->p_filesz, 0,


I try to incorporate your further comments and re-send the patch.

-- 
Alexander Boettcher
Genode Labs

http://www.genode-labs.com - http://www.genode.org

Genode Labs GmbH - Amtsgericht Dresden - HRB 28424 - Sitz Dresden
Geschäftsführer: Dr.-Ing. Norman Feske, Christian Helmuth

_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to