X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=hacks%2Fglx%2Fxlock-gl.c;h=d8cfd7a6bc40252ca213827669a3ab0753f791ef;hb=6bb727f03bff0389fbb1349d7df4c9d8d7532959;hp=28ee7ca3e0407144ede42b5f28b9c19828464031;hpb=5b7bc6e70fb439cf4c4bf771ae9f94077fe4fe08;p=xscreensaver diff --git a/hacks/glx/xlock-gl.c b/hacks/glx/xlock-gl.c index 28ee7ca3..d8cfd7a6 100644 --- a/hacks/glx/xlock-gl.c +++ b/hacks/glx/xlock-gl.c @@ -1,5 +1,5 @@ /* xlock-gc.c --- xscreensaver compatibility layer for xlockmore GL modules. - * xscreensaver, Copyright (c) 1997 Jamie Zawinski + * xscreensaver, Copyright (c) 1997, 1998 Jamie Zawinski * * Permission to use, copy, modify, distribute, and sell this software and its * documentation for any purpose is hereby granted without fee, provided that @@ -40,7 +40,7 @@ BadValue_ehandler (Display *dpy, XErrorEvent *error) } -GLXContext +GLXContext * init_GL(ModeInfo * mi) { Display *dpy = mi->dpy; @@ -88,7 +88,14 @@ init_GL(ModeInfo * mi) } } - return (glx_context); + /* GLXContext is already a pointer type. + Why this function returns a pointer to a pointer, I have no idea... + */ + { + GLXContext *ptr = (GLXContext *) malloc(sizeof(GLXContext)); + *ptr = glx_context; + return ptr; + } }