X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=openbox%2Fprop.c;h=0485045e344459938fb4f92d5fa132fe038f2c39;hb=82b2f0aa7a1723632e8d3cf7dc772e4bdb66868a;hp=6bd05cc6a4fe0163653c40a3adb3a86e303a1c3a;hpb=f506cbceae9e3d41f1e6e09d7c5e83ab3935adf9;p=chaz%2Fopenbox diff --git a/openbox/prop.c b/openbox/prop.c index 6bd05cc6..0485045e 100644 --- a/openbox/prop.c +++ b/openbox/prop.c @@ -328,7 +328,7 @@ gboolean prop_get_strings_locale(Window win, Atom prop, gchar ***ret) if (get_all(win, prop, prop_atoms.string, 8, (guchar**)&raw, &num)) { p = raw; - while (p < raw + num - 1) { + while (p < raw + num) { ++count; strs = g_slist_append(strs, p); p += strlen(p) + 1; /* next string */ @@ -377,7 +377,7 @@ gboolean prop_get_strings_utf8(Window win, Atom prop, gchar ***ret) if (get_all(win, prop, prop_atoms.utf8, 8, (guchar**)&raw, &num)) { p = raw; - while (p < raw + num - 1) { + while (p < raw + num) { ++count; strs = g_slist_append(strs, p); p += strlen(p) + 1; /* next string */