summaryrefslogtreecommitdiffstats
path: root/src/if_xcmdsrv.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2006-04-05 20:41:53 +0000
committerBram Moolenaar <Bram@vim.org>2006-04-05 20:41:53 +0000
commit910f66f90c928da8b607ccfdc12fc33d9cb8d4a9 (patch)
tree152a03d1d7ea3e8d433addba4f463d8a7a68a5fd /src/if_xcmdsrv.c
parente2f98b95c8071f772695602cd4f714dc588eb8e7 (diff)
updated for version 7.0c10v7.0c10
Diffstat (limited to 'src/if_xcmdsrv.c')
-rw-r--r--src/if_xcmdsrv.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/if_xcmdsrv.c b/src/if_xcmdsrv.c
index d19f50dd89..ef6e257410 100644
--- a/src/if_xcmdsrv.c
+++ b/src/if_xcmdsrv.c
@@ -1111,14 +1111,23 @@ GetRegProp(dpy, regPropp, numItemsp, domsg)
int result, actualFormat;
long_u bytesAfter;
Atom actualType;
+ XErrorHandler old_handler;
*regPropp = NULL;
+ old_handler = XSetErrorHandler(x_error_check);
+ got_x_error = FALSE;
+
result = XGetWindowProperty(dpy, RootWindow(dpy, 0), registryProperty, 0L,
(long)MAX_PROP_WORDS, False,
XA_STRING, &actualType,
&actualFormat, numItemsp, &bytesAfter,
regPropp);
+ XSync(dpy, FALSE);
+ (void)XSetErrorHandler(old_handler);
+ if (got_x_error)
+ return FAIL;
+
if (actualType == None)
{
/* No prop yet. Logically equal to the empty list */