xserver: Branch 'master'

Keith Packard keithp at kemper.freedesktop.org
Mon Nov 9 08:35:57 PST 2009


 randr/randrstr.h |   12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

New commits:
commit c7d1319872e0ae0b7d945e9af8c4027ee5aa2055
Author: Adam Jackson <ajax at redhat.com>
Date:   Mon Nov 9 11:12:22 2009 -0500

    randr: Fill in errorValue when verifying outputs/crtcs/modes
    
    Signed-off-by: Adam Jackson <ajax at redhat.com>
    Signed-off-by: Keith Packard <keithp at keithp.com>

diff --git a/randr/randrstr.h b/randr/randrstr.h
index af14374..975fe33 100644
--- a/randr/randrstr.h
+++ b/randr/randrstr.h
@@ -344,24 +344,30 @@ extern _X_EXPORT RESTYPE RRCrtcType, RRModeType, RROutputType;
     {\
 	int rc = dixLookupResourceByType((pointer *)&(ptr), id,\
 	                                 RROutputType, client, a);\
-	if (rc != Success)\
+	if (rc != Success) {\
+	    client->errorValue = id;\
 	    return (rc == BadValue) ? RRErrorBase + BadRROutput : rc;\
+	}\
     }
 
 #define VERIFY_RR_CRTC(id, ptr, a)\
     {\
 	int rc = dixLookupResourceByType((pointer *)&(ptr), id,\
 	                                 RRCrtcType, client, a);\
-	if (rc != Success)\
+	if (rc != Success) {\
+	    client->errorValue = id;\
 	    return (rc == BadValue) ? RRErrorBase + BadRRCrtc : rc;\
+	}\
     }
 
 #define VERIFY_RR_MODE(id, ptr, a)\
     {\
 	int rc = dixLookupResourceByType((pointer *)&(ptr), id,\
 	                                 RRModeType, client, a);\
-	if (rc != Success)\
+	if (rc != Success) {\
+	    client->errorValue = id;\
 	    return (rc == BadValue) ? RRErrorBase + BadRRMode : rc;\
+	}\
     }
 
 #define GetRRClient(pClient)    ((RRClientPtr)dixLookupPrivate(&(pClient)->devPrivates, RRClientPrivateKey))


More information about the xorg-commit mailing list