summaryrefslogtreecommitdiff
blob: 77ce7d536011246a337876218372dfcf0ca9924d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
--- nvidia-settings-1.0/src/libXNVCtrlAttributes/NvCtrlAttributesVidMode.c
+++ nvidia-settings-1.0/src/libXNVCtrlAttributes/NvCtrlAttributesVidMode.c
@@ -210,11 +210,12 @@
     if (vm) free(vm);
 
     /* restore the original error handler, if we overrode it */
-
+#if defined(X_XF86VidModeGetGammaRampSize)
     if (prev_error_handler) {
         XSetErrorHandler(prev_error_handler);
         prev_error_handler = NULL;
     }
+#endif
 
     return NULL;