On 12/03/2010 12:44 PM, Erkki Seppälä wrote:
  static XEXT_GENERATE_FIND_DISPLAY (find_display, xres_ext_info,
-                                   xres_extension_name,
+                                   xres_extension_name,
                                     &xres_extension_hooks,
                                     0, NULL)

@@ -189,7 +189,7 @@ Status XResQueryClientResources (
              _XEatData(dpy, rep.length<<  2);
          }
      }
-
+
      UnlockDisplay (dpy);
      SyncHandle ();
      return result;

Let's clean the dummy changes from the patch.

+static Bool ReadClientValues(
+   Display              *dpy,
+   long                 num_ids,
+   XResClientIdValue   *client_ids /* out */
+)
+{
+    int c;
+    for (c = 0; c<  num_ids; ++c) {
+        XResClientIdValue* client = client_ids + c;
+        _XRead32 (dpy,&client->spec.client, 4);
+        _XRead32 (dpy,&client->spec.mask, 4);
+        _XRead32 (dpy,&client->length, 4);
+        client->value = malloc(client->length);
+        _XRead32 (dpy, client->value, client->length);
+    }
+    return True;
+}

Check if memory allocation failed.

-- Rami

_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to