dumb_display_init() crash
PATCH 1/1 dumb_display_init() crash
This fixes a crash for the 405 boards that don't do a display init. I would think this is correct but I am not sure if there is more that needs to be setup. This at least gets me back to the SDL display I use to see before the re-org.
trunk/vl.c +6 -0
@@ -2778,6 +2778,12 @@ DisplayState *get_displaystate(void)static void dumb_display_init (void ) {DisplayState *ds =qemu_mallocz (sizeof (DisplayState)); + +if (ds ==NULL ) +return ; + + ds->surface =qemu_create_displaysurface (640 ,480 ,32 ,640 *4 ); +register_displaystate (ds); }
Quoted 4 lines · Andrew May
This fixes a crash for the 405 boards that don't do a display init. I would think this is correct but I am not sure if there is more that needs to be setup. This at least gets me back to the SDL display I use to see before the re-org.
Your fix is correct, I am just going to repost your patch adding signed-off-lines and changing the return NULL into exit(1) in case the malloc fails.