--- rxvt-unicode/src/main.C 2006/07/06 23:48:11 1.226 +++ rxvt-unicode/src/main.C 2006/08/27 10:10:25 1.230 @@ -58,10 +58,15 @@ bool rxvt_set_locale (const char *locale) NOTHROW { - if (!locale || !strncmp (locale, curlocale, 128)) + int size = strlen (locale) + 1; + + if (size > sizeof (curlocale)) + rxvt_fatal ("locale string too long, aborting.\n"); + + if (!locale || !memcmp (locale, curlocale, size)) return false; - strncpy (curlocale, locale, 128); + memcpy (curlocale, locale, size); setlocale (LC_CTYPE, curlocale); return true; } @@ -267,9 +272,9 @@ clear (); } - delete pix_colors_focused; + delete [] pix_colors_focused; #if OFF_FOCUS_FADING - delete pix_colors_unfocused; + delete [] pix_colors_unfocused; #endif displays.put (display); @@ -809,7 +814,8 @@ prop = (*fs)[1]->properties (); prop.height += lineSpace; - fs->set_prop (prop); + + fs->set_prop (prop, false); fwidth = prop.width; fheight = prop.height; @@ -838,7 +844,7 @@ } fs->populate (res); - fs->set_prop (prop2); + fs->set_prop (prop2, true); } #else fontset[style] = fontset[0];