struct _glxapi_table *t;
Display *dpy = glXGetCurrentDisplay();
GET_DISPATCH(dpy, t);
- if (!t)
- return 0;
+ if (!t || !glXGetCurrentContext())
+ return GLX_BAD_CONTEXT;
return (t->GetVideoSyncSGI)(count);
}
struct _glxapi_table *t;
Display *dpy = glXGetCurrentDisplay();
GET_DISPATCH(dpy, t);
- if (!t)
- return 0;
+ if (!t || !glXGetCurrentContext())
+ return GLX_BAD_CONTEXT;
return (t->WaitVideoSyncSGI)(divisor, remainder, count);
}
struct _glxapi_table *t;
GET_DISPATCH(dpy, t);
if (!t)
- return 0;
+ return False;
return (t->MakeCurrentReadSGI)(dpy, draw, read, ctx);
}