diff options
author | marha <marha@users.sourceforge.net> | 2012-08-16 14:52:47 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-08-16 14:52:47 +0200 |
commit | e12a88a1a4897365d47e428bceda547a4e02fbd0 (patch) | |
tree | 116944397f595fd9b72d8de3b0a3783ccf3937ef /mesalib/src/mesa/drivers/dri/swrast | |
parent | f5a4fa87e844b3ea2658a2355a4c4ac3393a65a1 (diff) | |
parent | 4aac32998c2b173b84aec0b020aa086fef4b1423 (diff) | |
download | vcxsrv-e12a88a1a4897365d47e428bceda547a4e02fbd0.tar.gz vcxsrv-e12a88a1a4897365d47e428bceda547a4e02fbd0.tar.bz2 vcxsrv-e12a88a1a4897365d47e428bceda547a4e02fbd0.zip |
Merge remote-tracking branch 'origin/released'
Diffstat (limited to 'mesalib/src/mesa/drivers/dri/swrast')
-rw-r--r-- | mesalib/src/mesa/drivers/dri/swrast/swrast.c | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/mesalib/src/mesa/drivers/dri/swrast/swrast.c b/mesalib/src/mesa/drivers/dri/swrast/swrast.c index 61cbb6add..28177cbe0 100644 --- a/mesalib/src/mesa/drivers/dri/swrast/swrast.c +++ b/mesalib/src/mesa/drivers/dri/swrast/swrast.c @@ -724,11 +724,20 @@ dri_create_context(gl_api api, */ (void) flags; - if (api == API_OPENGL - && (major_version > 2 - || (major_version == 2 && minor_version > 1))) { - *error = __DRI_CTX_ERROR_BAD_VERSION; - goto context_fail; + switch (api) { + case API_OPENGL: + if (major_version > 2 + || (major_version == 2 && minor_version > 1)) { + *error = __DRI_CTX_ERROR_BAD_VERSION; + return GL_FALSE; + } + break; + case API_OPENGLES: + case API_OPENGLES2: + break; + case API_OPENGL_CORE: + *error = __DRI_CTX_ERROR_BAD_API; + return GL_FALSE; } ctx = CALLOC_STRUCT(dri_context); |