aboutsummaryrefslogtreecommitdiff
path: root/libX11/src/XlibInt.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-02-03 11:20:18 +0000
committermarha <marha@users.sourceforge.net>2011-02-03 11:20:18 +0000
commit46fbac6f1b19416ee1dbca883f0d09d9fd75d1eb (patch)
tree2ddc90cb6bc4f04db80d66a334ecaabf139c0176 /libX11/src/XlibInt.c
parent97f3d3043a79d6031787c246a67d2a02ff0a8d08 (diff)
parent83a4fe0dc71aafbef11477b284abe530d3877556 (diff)
downloadvcxsrv-46fbac6f1b19416ee1dbca883f0d09d9fd75d1eb.tar.gz
vcxsrv-46fbac6f1b19416ee1dbca883f0d09d9fd75d1eb.tar.bz2
vcxsrv-46fbac6f1b19416ee1dbca883f0d09d9fd75d1eb.zip
svn merge ^/branches/released .
Diffstat (limited to 'libX11/src/XlibInt.c')
-rw-r--r--libX11/src/XlibInt.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/libX11/src/XlibInt.c b/libX11/src/XlibInt.c
index 498cf16be..33bbe5458 100644
--- a/libX11/src/XlibInt.c
+++ b/libX11/src/XlibInt.c
@@ -668,6 +668,7 @@ XAddConnectionWatch(
UnlockDisplay(dpy);
return 0;
}
+ info_list->watch_data = wd_array;
wd_array[dpy->watcher_count] = NULL; /* for cleanliness */
}
@@ -1444,9 +1445,10 @@ static int _XPrintDefaultError(
ext && (ext->codes.major_opcode != event->request_code);
ext = ext->next)
;
- if (ext)
- strcpy(buffer, ext->name);
- else
+ if (ext) {
+ strncpy(buffer, ext->name, BUFSIZ);
+ buffer[BUFSIZ - 1] = '\0';
+ } else
buffer[0] = '\0';
}
(void) fprintf(fp, " (%s)\n", buffer);