- XGetWindowProperty(_display, win, atom, 0l, 1l, False, AnyPropertyType,
- &ret_type, &ret_size, &nelements, &ret_bytes, &c_val);
- if (ret_type == None || nelements < 1)
- // the property does not exist on the window or is empty
+ result = XGetWindowProperty(_display, win, atom, 0l, 1l, False,
+ AnyPropertyType, &ret_type, &ret_size,
+ &nelements, &ret_bytes, &c_val);
+ if (result != Success || ret_type == None || nelements < 1)
+ // an error occured, the property does not exist on the window, or is empty