aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/xfixes/xfixes.h
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2009-09-09 05:23:48 +0000
committermarha <marha@users.sourceforge.net>2009-09-09 05:23:48 +0000
commit81f91c615982e50bb62708201569c33a3cd3d973 (patch)
tree4f32ecc48a3b7b5e76642f3792338263c53879bd /xorg-server/xfixes/xfixes.h
parentb571a562410f565af2bdde52d9f7f9a23ffae04f (diff)
parenta915739887477b28d924ecc8417ee107d125bd6c (diff)
downloadvcxsrv-81f91c615982e50bb62708201569c33a3cd3d973.tar.gz
vcxsrv-81f91c615982e50bb62708201569c33a3cd3d973.tar.bz2
vcxsrv-81f91c615982e50bb62708201569c33a3cd3d973.zip
svn merge https://vcxsrv.svn.sourceforge.net/svnroot/vcxsrv/branches/released .
Diffstat (limited to 'xorg-server/xfixes/xfixes.h')
-rw-r--r--xorg-server/xfixes/xfixes.h28
1 files changed, 17 insertions, 11 deletions
diff --git a/xorg-server/xfixes/xfixes.h b/xorg-server/xfixes/xfixes.h
index 81dd83daf..69d162ffe 100644
--- a/xorg-server/xfixes/xfixes.h
+++ b/xorg-server/xfixes/xfixes.h
@@ -29,23 +29,29 @@
#include "resource.h"
-extern RESTYPE RegionResType;
-extern int XFixesErrorBase;
-
-#define VERIFY_REGION(pRegion, rid, client, mode) { \
- pRegion = SecurityLookupIDByType (client, rid, RegionResType, mode); \
- if (!pRegion) { \
- client->errorValue = rid; \
- return XFixesErrorBase + BadRegion; \
- } \
-}
+extern _X_EXPORT RESTYPE RegionResType;
+extern _X_EXPORT int XFixesErrorBase;
+
+#define VERIFY_REGION(pRegion, rid, client, mode) \
+ do { \
+ int err; \
+ err = dixLookupResourceByType((pointer *) &pRegion, rid, \
+ RegionResType, client, mode); \
+ if (err == BadValue) { \
+ client->errorValue = rid; \
+ return XFixesErrorBase + BadRegion; \
+ } else if (err != Success) { \
+ client->errorValue = rid; \
+ return err; \
+ } \
+ } while (0)
#define VERIFY_REGION_OR_NONE(pRegion, rid, client, mode) { \
pRegion = 0; \
if (rid) VERIFY_REGION(pRegion, rid, client, mode); \
}
-RegionPtr
+extern _X_EXPORT RegionPtr
XFixesRegionCopy (RegionPtr pRegion);