[Qemu-devel] [PATCH v2] linux-user/mmap.c: Avoid choosing NULL as start address

2018-01-06 Thread Maximilian Riemensberger
ailed. This patch fixes mmap_find_vma_reserved() by skipping NULL as start address while searching for a suitable mapping start address. CC: Riku Voipio CC: Laurent Vivier CC: Peter Maydell Signed-off-by: Maximilian Riemensberger --- Changes since v1: - Applied feedback from Laurent V

Re: [Qemu-devel] [PATCH] linux-user/mmap.c: Avoid choosing NULL as start address

2018-01-06 Thread Maximilian Riemensberger
On 06.01.18 21:51, Laurent Vivier wrote: > Le 06/01/2018 à 18:00, Maximilian Riemensberger a écrit : >> mmap() is required by the linux kernel ABI and POSIX to return a >> non-NULL address when the implementation chooses a start address for the >> mapping. >> >&

Re: [Qemu-devel] [PATCH] linux-user/mmap.c: Avoid choosing NULL as start address

2018-01-06 Thread Maximilian Riemensberger
On 06.01.18 18:00, Maximilian Riemensberger wrote: > mmap() is required by the linux kernel ABI and POSIX to return a > non-NULL address when the implementation chooses a start address for the > mapping. > > The current implementation of mmap_find_vma_reserved() can return NULL >

Re: [Qemu-devel] linux-user/mmap: Should not return NULL on guest call mmap(NULL, ...), causes crash inside glibc

2018-01-06 Thread Maximilian Riemensberger
On 05.01.18 22:13, Maximilian Riemensberger wrote: > On 05.01.18 19:38, Peter Maydell wrote: >> On 5 January 2018 at 18:13, Maximilian Riemensberger >> wrote: >>> Hi, >>> >>> yesterday I hit the following problem when running an arm linux executable >

[Qemu-devel] [PATCH] linux-user/mmap.c: Avoid choosing NULL as start address

2018-01-06 Thread Maximilian Riemensberger
ailed. This patch fixes mmap_find_vma_reserved() by skipping NULL as start address while searching for a suitable mapping start address. CC: Riku Voipio CC: Laurent Vivier CC: Peter Maydell Signed-off-by: Maximilian Riemensberger --- linux-user/mmap.c | 2 +- 1 file changed, 1 insertion(

Re: [Qemu-devel] linux-user/mmap: Should not return NULL on guest call mmap(NULL, ...), causes crash inside glibc

2018-01-05 Thread Maximilian Riemensberger
On 05.01.18 19:38, Peter Maydell wrote: > On 5 January 2018 at 18:13, Maximilian Riemensberger > wrote: >> Hi, >> >> yesterday I hit the following problem when running an arm linux executable on >> qemu-2.10 (qemu-arm-static through binfmt_misc) >> >

[Qemu-devel] linux-user/mmap: Should not return NULL on guest call mmap(NULL, ...), causes crash inside glibc

2018-01-05 Thread Maximilian Riemensberger
0331 Munich, Germany Contact: +49-176-63360306, riemensber...@cadami.net, www.cadami.net Geschäftsführer: Andreas Dotzler, Michael Heindlmaier, Thomas Kühn, Maximilian Riemensberger Sitz der Gesellschaft: Eching, HRB 219979 Amtsgericht München USt-IdNr.: DE301293803 --