From 681069d7a42d955a3cbe302f40564f4266185908 Mon Sep 17 00:00:00 2001 From: Mike Gabriel Date: Thu, 13 Apr 2017 12:01:07 +0200 Subject: nxcompshad/Shadow.cpp: Use EBADF instead of EBADFD (which is not portable to GNU/Hurd and GNU/kFreeBSD). We use the error code (and its underlying message for generating log errors and their textual messages. So, in theory, we could use any error code here. Thus, choosing the once closest to EBADFD while being portable to non-Linux systems. --- nxcompshad/Shadow.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'nxcompshad') diff --git a/nxcompshad/Shadow.cpp b/nxcompshad/Shadow.cpp index 4a28f2c52..643a5a807 100644 --- a/nxcompshad/Shadow.cpp +++ b/nxcompshad/Shadow.cpp @@ -144,7 +144,7 @@ static int NXCreatePoller(Display *display, Display **shadowDisplay) if (input == NULL) { - logError("NXCreatePoller", ESET(EBADFD)); + logError("NXCreatePoller", ESET(EBADF)); return -1; } @@ -179,7 +179,7 @@ static int NXCreateUpdateManager() if (input == NULL || poller == NULL) { - logError("NXCreateUpdateManager", ESET(EBADFD)); + logError("NXCreateUpdateManager", ESET(EBADF)); return -1; } @@ -354,7 +354,7 @@ void NXShadowHandleInput() if (NXShadowNotInitialized()) { - logError("NXShadowHandleInput - NXShadow not properly initialized.", ESET(EBADFD)); + logError("NXShadowHandleInput - NXShadow not properly initialized.", ESET(EBADF)); return; } @@ -374,7 +374,7 @@ int NXShadowHasChanged(int (*callback)(void *), void *arg, int *suspended) if (NXShadowNotInitialized()) { - logError("NXShadowHasChanged - NXShadow not properly initialized.", ESET(EBADFD)); + logError("NXShadowHasChanged - NXShadow not properly initialized.", ESET(EBADF)); return -1; } @@ -415,7 +415,7 @@ void NXShadowExportChanges(long *numRects, char **pBox) if (NXShadowNotInitialized()) { - logError("NXShadowExportChanges - NXShadow not properly initialized.", ESET(EBADFD)); + logError("NXShadowExportChanges - NXShadow not properly initialized.", ESET(EBADF)); } updateManager -> update(); -- cgit v1.2.3