st/wgl: Return NULL for NULL HDCs in wglGetExtensionsStringARB.
[mesa.git] / src / gallium / state_trackers / wgl / stw_ext_extensionsstring.c
index 62c859e1f92cc0601d707e66b0d6086686ec8788..7cad49c9f840efc3f62e5b1911676012186c5857 100644 (file)
@@ -37,6 +37,7 @@
 static const char *stw_extension_string = 
    "WGL_ARB_extensions_string "
    "WGL_ARB_multisample "
+   "WGL_ARB_pbuffer "
    "WGL_ARB_pixel_format "
 /*   "WGL_EXT_swap_interval " */
    "WGL_EXT_extensions_string";
@@ -46,7 +47,9 @@ WINGDIAPI const char * APIENTRY
 wglGetExtensionsStringARB(
    HDC hdc )
 {
-   (void) hdc;
+   if (!hdc) {
+      return NULL;
+   }
 
    return stw_extension_string;
 }