xserver: Branch 'master'
Adam Jackson
ajax at kemper.freedesktop.org
Mon Sep 25 19:39:48 UTC 2017
test/simple-xinit.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 0888b22fea71118b1a9a238134b3b8d1dc659734
Author: Adam Jackson <ajax at redhat.com>
Date: Mon Sep 25 15:01:32 2017 -0400
test: Fix a thinko in simple-xinit
Spotted by clang courtesy of the shiny new OSX Travis target:
simple-xinit.c:90:65: warning: sizeof on pointer operation will return size of 'char *' instead of 'char [10]' [-Wsizeof-array-decay]
ret = read(displayfd, display_string, sizeof(display_string - 1));
Signed-off-by: Adam Jackson <ajax at redhat.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith at oracle.com>
diff --git a/test/simple-xinit.c b/test/simple-xinit.c
index 1fc31be26..26ff12bf7 100644
--- a/test/simple-xinit.c
+++ b/test/simple-xinit.c
@@ -87,7 +87,7 @@ get_display(int displayfd)
char display_string[10];
ssize_t ret;
- ret = read(displayfd, display_string, sizeof(display_string - 1));
+ ret = read(displayfd, display_string, sizeof(display_string) - 1);
if (ret <= 0) {
fprintf(stderr, "Failed reading displayfd: %s\n", strerror(errno));
exit(1);
More information about the xorg-commit
mailing list