tests/kms-steal-crtc: Include sys/select.h
PATCH 1/1 tests/kms-steal-crtc: Include sys/select.h
Fixes errors e.g.
error: implicit declaration of function 'select'
and missing definitions of FD_* defines
--- tests/kms/kms-steal-crtc.c | 1 + 1 file changed, 1 insertion(+)
tests/kms/kms-steal-crtc.c +1 -0
@@ -31,6 +31,7 @@#include <stdio.h> #include <string.h> #include <unistd.h> +#include <sys/select.h> #include <drm_fourcc.h>
Signature · 6 lines
2.6.4 _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
Quoted 16 lines · Khem Raj
Fixes errors e.g.
error: implicit declaration of function 'select'
and missing definitions of FD_* defines
Signed-off-by Khem Raj <[email protected]>--- tests/kms/kms-steal-crtc.c | 1 + 1 file changed, 1 insertion(+)tests/kms/kms-steal-crtc.c +0
-0
tests/kms/kms-steal-crtc.c line 34
Quoted 4 lines
tests/kms/kms-steal-crtc.c +1
-0@@ -31,6 +31,7 @@#include <stdio.h> #include <string.h> #include <unistd.h> +#include <sys/select.h>
This must be pulled in some other way on my system, but this looks correct:
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Quoted 12 lines · Thierry Reding
Quoted 11 lines · Khem Raj
Fixes errors e.g.
error: implicit declaration of function 'select'
and missing definitions of FD_* defines
Signed-off-by Khem Raj <[email protected]>--- tests/kms/kms-steal-crtc.c | 1 + 1 file changed, 1 insertion(+)
Quoted 13 lines
tests/kms/kms-steal-crtc.c line 34
Quoted 9 lines
tests/kms/kms-steal-crtc.c +1
-0@@ -31,6 +31,7 @@#include <stdio.h> #include <string.h> #include <unistd.h> +#include <sys/select.h> This must be pulled in some other way on my system, but this looks correct:
The above header is required/used in compliance with POSIX 2001/2008. Earlier standards use the below three.
#include <sys/time.h>
#include <sys/types.h>
#include <unistd.h>
I'm not sure how much we should care about platforms non-compliant to POSIX 2001... although adding the header check seems pretty trivial. Add the new one in the list at configure.ac:AC_CHECK_HEADERS and wrap the include in a ifdef guard.
From a quick grep there are a few other users of select()
tests/kms/kms-steal-crtc.ctests/kms/kms-universal-planes.ctests/modetest/modetest.ctests/vbltest/vbltest.c
Raj, can you update the patch to handle the lot (one patch should be ok imho) ?
Thanks
Emil
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel