Xserver has struct members named `bool`, which means the last commit
breaks its build with errors like this:
error: two or more data types in declaration specifiers
Bool bool;
^
Fix this by making it return a 0/1 integer, with the same semantic as
the boolean it was before.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=109587
Fixes:
17dfe3ac93217b43f93b "xf86drm: Add drmIsMaster()"
Cc: Christopher James Halse Rogers <christopher.halse.rogers@canonical.com>
Signed-off-by: Eric Engestrom <eric.engestrom@intel.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
return drmIoctl(fd, DRM_IOCTL_DROP_MASTER, NULL);
}
-drm_public bool drmIsMaster(int fd)
+drm_public int drmIsMaster(int fd)
{
/* Detect master by attempting something that requires master.
*
#include <stdarg.h>
#include <sys/types.h>
#include <stdint.h>
-#include <stdbool.h>
#include <drm.h>
#if defined(__cplusplus)
extern int drmSetMaster(int fd);
extern int drmDropMaster(int fd);
-extern bool drmIsMaster(int fd);
+extern int drmIsMaster(int fd);
#define DRM_EVENT_CONTEXT_VERSION 4