From: Ben H. <be...@ex...> - 2001-11-15 04:09:32
|
Csopengl.h: ----- typedef struct HG3D { unsigned type : 1; HWND wnd; HDC gdi; HGLRC glctxt; HBITMAP image; } G3D, * HG3D; ----- Csopengl.c: ----- ctxt = (HG3D) malloc(sizeof(HG3D)); if(!ctxt) return NULL; ----- I am not sure but shouldn't it be "sizeof(G3D)" and not "sizeof(HG3D)"? Otherwise wouldn't there be a memory overrun? Cheers, -ben houston 4th Year Cognitive Science/Neuroscience Carleton University, Ottawa, Canada ( be...@ex... / 613-266-0637 ) |