Re: [PATCH] ui/sdl2: Check return value from g_setenv()

2021-08-10 Thread Gerd Hoffmann
On Mon, Aug 09, 2021 at 05:14:24PM +0100, Peter Maydell wrote: > Setting environment variables can fail; check the return value > from g_setenv() and bail out if we couldn't set SDL_VIDEODRIVER. > > Fixes: Coverity 1458798 > Signed-off-by: Peter Maydell > --- > I followed existing practice in thi

Re: [PATCH] ui/sdl2: Check return value from g_setenv()

2021-08-09 Thread Gerd Hoffmann
Hi, > Setting environment variables can fail; check the return value > from g_setenv() and bail out if we couldn't set SDL_VIDEODRIVER. Hmm, looking at the comment I'm wondering whenever we maybe should just drop the setenv (after 6.1). It's quite old, I doubt svgalib talking directly to the h

[PATCH] ui/sdl2: Check return value from g_setenv()

2021-08-09 Thread Peter Maydell
Setting environment variables can fail; check the return value from g_setenv() and bail out if we couldn't set SDL_VIDEODRIVER. Fixes: Coverity 1458798 Signed-off-by: Peter Maydell --- I followed existing practice in this function for how it deals with errors (ie, fprintf to stderr and exit). ---