xproperty: Don't limit property lengths

All that I can say is "oops, I blame copy&paste".

Thanks to Elv13 for noticing this.

Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
Uli Schlachter 2014-03-09 20:22:44 +01:00
parent 2ac95b4ae8
commit 642ab35988
1 changed files with 3 additions and 1 deletions

View File

@ -363,11 +363,13 @@ luaA_window_get_xproperty(lua_State *L)
xcb_atom_t type;
void *data;
xcb_get_property_reply_t *reply;
uint32_t length;
type = prop->type == PROP_STRING ? UTF8_STRING : XCB_ATOM_CARDINAL;
length = prop->type == PROP_STRING ? UINT32_MAX : 1;
reply = xcb_get_property_reply(globalconf.connection,
xcb_get_property_unchecked(globalconf.connection, false, w->window,
prop->atom, type, 0, 4), NULL);
prop->atom, type, 0, length), NULL);
if(!reply)
return 0;