[PATCH] fs: remove implicit compiler calls to memset/memcpy

2016-04-10 Thread Pete Batard
Hi, I am using the GRUB codebase to build generic read-only EFI file system drivers [1] and during that process, I found that some compilers (e.g. MSVC, but most likely others) may insert implicit calls to memset/memcpy when initializing or copying structure content, which defeats the use of

Re: [PATCH] fs: remove implicit compiler calls to memset/memcpy

2016-04-10 Thread Vladimir 'phcoder' Serbinenko
Le dim. 10 avr. 2016 15:53, Pete Batard a écrit : > Hi, > > I am using the GRUB codebase to build generic read-only EFI file system > drivers [1] and during that process, I found that some compilers (e.g. > MSVC, but most likely others) may insert implicit calls to memset/memcpy > when initializi

Re: [PATCH] fs: remove implicit compiler calls to memset/memcpy

2016-04-10 Thread Pete Batard
On 2016.04.10 16:30, Vladimir 'phcoder' Serbinenko wrote: Why is the same solution not suitable for you? That's the first thing I attempted, but the MSVC compiler is uncooperative. If you try to redefine memset/memcpy, you get the following compiler error: error C2169: '_memcpy' : Intrinsic f

Re: [PATCH] verify: search keyid in hashed signature subpackets

2016-04-10 Thread Ignat Korchagin
> TBH I still think that simply setting READBUF_SIZE to 64K is the simplest > solution. I would agree, but I was just a little concerned about allocating large buffer. I'm not sure whether GRUB is considered to be able to run on very resource constrained environments and it seemed that per-subpac

Re: [PATCH] grub-file: fix segmentation fault

2016-04-10 Thread Michael Chang
On Sat, Apr 09, 2016 at 07:01:50AM +0300, Andrei Borzenkov wrote: > 08.04.2016 09:43, Michael Chang пишет: > > In grub_file_open the file handle returned by file filters has no file->name > > set which leads to segmentation fault later referenced by grub_elf_file. We > > move the file->name value a