summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Huddleston <jeremyhu@apple.com>2011-07-21 10:33:58 -0700
committerJeremy Huddleston <jeremyhu@apple.com>2011-08-04 22:56:03 -0700
commit4fdc6706ca32042edcedc2f831e6f09e1660101b (patch)
tree24567c4dea77b233261c708b1d2710afd78cb49f
parentd97501fffcad67cdc4709514ee98c7b7298df9dc (diff)
XQuartz: xpr: Don't FatalError if xp_unlock_window fails
We added the FatalError in 5d1d9d9ae39fab2ee2ac085f9776f82768828dc8 but it caused a regression http://xquartz.macosforge.org/trac/ticket/482 Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com> (cherry picked from commit a1bb5062c72667b2f10b56925c61888acc89e3e4)
-rw-r--r--hw/xquartz/xpr/xprFrame.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/hw/xquartz/xpr/xprFrame.c b/hw/xquartz/xpr/xprFrame.c
index 15598e942..931b5c5ce 100644
--- a/hw/xquartz/xpr/xprFrame.c
+++ b/hw/xquartz/xpr/xprFrame.c
@@ -217,7 +217,7 @@ xprDestroyFrame(RootlessFrameID wid)
err = xp_destroy_window(x_cvt_vptr_to_uint(wid));
if (err != Success)
- FatalError("Could not destroy window %i.", (int)x_cvt_vptr_to_uint(wid));
+ FatalError("Could not destroy window %d (%d).", (int)x_cvt_vptr_to_uint(wid), (int)err);
}
@@ -360,7 +360,7 @@ xprStartDrawing(RootlessFrameID wid, char **pixelData, int *bytesPerRow)
err = xp_lock_window(x_cvt_vptr_to_uint(wid), NULL, NULL, data, rowbytes, NULL);
if (err != Success)
- FatalError("Could not lock window %i for drawing.", (int)x_cvt_vptr_to_uint(wid));
+ FatalError("Could not lock window %d for drawing (%d).", (int)x_cvt_vptr_to_uint(wid), (int)err);
*pixelData = data[0];
*bytesPerRow = rowbytes[0];
@@ -377,8 +377,11 @@ xprStopDrawing(RootlessFrameID wid, Bool flush)
TA_SERVER();
err = xp_unlock_window(x_cvt_vptr_to_uint(wid), flush);
+ /* This should be a FatalError, but we started tripping over it. Make it a
+ * FatalError after http://xquartz.macosforge.org/trac/ticket/482 is fixed.
+ */
if(err != Success)
- FatalError("Could not unlock window %i after drawing.", (int)x_cvt_vptr_to_uint(wid));
+ ErrorF("Could not unlock window %d after drawing (%d).", (int)x_cvt_vptr_to_uint(wid), (int)err);
}