mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 11:00:11 +01:00
added an error check
This commit is contained in:
parent
99aab34199
commit
db30cc8d00
1 changed files with 10 additions and 3 deletions
|
|
@ -1,4 +1,4 @@
|
|||
/* $Id: glxdemo.c,v 1.1 1999/08/19 00:55:43 jtg Exp $ */
|
||||
/* $Id: glxdemo.c,v 1.2 2002/04/02 23:53:56 brianp Exp $ */
|
||||
|
||||
|
||||
/*
|
||||
|
|
@ -11,8 +11,11 @@
|
|||
|
||||
/*
|
||||
* $Log: glxdemo.c,v $
|
||||
* Revision 1.1 1999/08/19 00:55:43 jtg
|
||||
* Initial revision
|
||||
* Revision 1.2 2002/04/02 23:53:56 brianp
|
||||
* added an error check
|
||||
*
|
||||
* Revision 1.1.1.1 1999/08/19 00:55:43 jtg
|
||||
* Imported sources
|
||||
*
|
||||
* Revision 3.0 1998/02/21 02:16:54 brianp
|
||||
* initial rev
|
||||
|
|
@ -90,6 +93,10 @@ static Window make_rgb_db_window( Display *dpy,
|
|||
visinfo->visual, mask, &attr );
|
||||
|
||||
ctx = glXCreateContext( dpy, visinfo, NULL, True );
|
||||
if (!ctx) {
|
||||
printf("Error: glXCreateContext failed\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
glXMakeCurrent( dpy, win, ctx );
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue