X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;ds=sidebyside;f=openbox%2Fscreen.c;h=a562566ebe1bb1f2f3bb3db3bf91daf01e3a8a56;hb=1430d59e96616435fdac4aad5a7713d3aae1ef83;hp=0563148e95a4e0ce56fcf57338d74e24e8720166;hpb=eb6a2e9c4b334f53d714a2e7f10f73c63c3d2edd;p=chaz%2Fopenbox diff --git a/openbox/screen.c b/openbox/screen.c index 0563148e..a562566e 100644 --- a/openbox/screen.c +++ b/openbox/screen.c @@ -1098,10 +1098,9 @@ void screen_install_colormap(ObClient *client, gboolean install) monitor_area[i].x, monitor_area[i].width)) #define RESET_STRUT_LIST(sl) \ - {for (i = 0; sl[i]; ++i) \ - g_slist_free(sl[i]); \ + {if (sl) for (i = 0; sl[i]; ++i) g_slist_free(sl[i]); \ sl = g_renew(GSList*, sl, screen_num_desktops + 1); \ - sl[screen_num_desktops] = NULL;} /* null terminated */ + memset(sl, sizeof(GSList*) * screen_num_desktops, NULL);} #define ADD_STRUT_TO_LIST(sl, d, s) \ {for (i = 0; i < screen_num_desktops; ++i) \