diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c
index 8208a50..4c2c32e 100644
--- a/src/mesa/main/context.c
+++ b/src/mesa/main/context.c
@@ -1507,7 +1507,10 @@
    GLenum buffer;
    GLint bufferIndex;
 
-   assert(ctx->Version > 0);
+   if (ctx->Version == 0) {
+      /* probably in the process of tearing down the context */
+      return;
+   }
 
    ctx->Extensions.String = _mesa_make_extension_string(ctx);
 
diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c
index 09b6154..768a667 100644
--- a/src/mesa/state_tracker/st_context.c
+++ b/src/mesa/state_tracker/st_context.c
@@ -104,6 +104,42 @@
    _vbo_InvalidateState(ctx, new_state);
 }
 
+
+static void
+st_destroy_context_priv(struct st_context *st)
+{
+   uint shader, i;
+
+   st_destroy_atoms( st );
+   st_destroy_draw( st );
+   st_destroy_clear(st);
+   st_destroy_bitmap(st);
+   st_destroy_drawpix(st);
+   st_destroy_drawtex(st);
+
+   for (shader = 0; shader < Elements(st->state.sampler_views); shader++) {
+      for (i = 0; i < Elements(st->state.sampler_views[0]); i++) {
+         pipe_sampler_view_release(st->pipe,
+                                   &st->state.sampler_views[shader][i]);
+      }
+   }
+
+   if (st->default_texture) {
+      st->ctx->Driver.DeleteTexture(st->ctx, st->default_texture);
+      st->default_texture = NULL;
+   }
+
+   u_upload_destroy(st->uploader);
+   if (st->indexbuf_uploader) {
+      u_upload_destroy(st->indexbuf_uploader);
+   }
+   if (st->constbuf_uploader) {
+      u_upload_destroy(st->constbuf_uploader);
+   }
+   free( st );
+}
+
+
 static struct st_context *
 st_create_context_priv( struct gl_context *ctx, struct pipe_context *pipe,
 		const struct st_config_options *options)
@@ -238,6 +274,14 @@
 
    _mesa_compute_version(ctx);
 
+   if (ctx->Version == 0) {
+      /* This can happen when a core profile was requested, but the driver
+       * does not support some features of GL 3.1 or later.
+       */
+      st_destroy_context_priv(st);
+      return NULL;
+   }
+
    _mesa_initialize_dispatch_tables(ctx);
    _mesa_initialize_vbo_vtxfmt(ctx);
 
@@ -259,6 +303,7 @@
    struct gl_context *ctx;
    struct gl_context *shareCtx = share ? share->ctx : NULL;
    struct dd_function_table funcs;
+   struct st_context *st;
 
    memset(&funcs, 0, sizeof(funcs));
    st_init_driver_functions(&funcs);
@@ -276,41 +321,12 @@
    if (debug_get_option_mesa_mvp_dp4())
       ctx->Const.ShaderCompilerOptions[MESA_SHADER_VERTEX].OptimizeForAOS = GL_TRUE;
 
-   return st_create_context_priv(ctx, pipe, options);
-}
-
-
-static void st_destroy_context_priv( struct st_context *st )
-{
-   uint shader, i;
-
-   st_destroy_atoms( st );
-   st_destroy_draw( st );
-   st_destroy_clear(st);
-   st_destroy_bitmap(st);
-   st_destroy_drawpix(st);
-   st_destroy_drawtex(st);
-
-   for (shader = 0; shader < Elements(st->state.sampler_views); shader++) {
-      for (i = 0; i < Elements(st->state.sampler_views[0]); i++) {
-         pipe_sampler_view_release(st->pipe,
-                                   &st->state.sampler_views[shader][i]);
-      }
+   st = st_create_context_priv(ctx, pipe, options);
+   if (!st) {
+      _mesa_destroy_context(ctx);
    }
 
-   if (st->default_texture) {
-      st->ctx->Driver.DeleteTexture(st->ctx, st->default_texture);
-      st->default_texture = NULL;
-   }
-
-   u_upload_destroy(st->uploader);
-   if (st->indexbuf_uploader) {
-      u_upload_destroy(st->indexbuf_uploader);
-   }
-   if (st->constbuf_uploader) {
-      u_upload_destroy(st->constbuf_uploader);
-   }
-   free( st );
+   return st;
 }
 
 
