Developer forums (C::B DEVELOPMENT STRICTLY!) > Development
glfw.png bad
(1/1)
tiwag:
since the latest CVS commit regarding the glfw-template, C::B gives a Fatal Error when trying to create a New Project !
the problem is a bad <CodeBlocks-CVS-dir>\src\templates\common\glfw.png file
- workaround for now :
delete this file: <CodeBlocks-install-dir>\share\CodeBlocks\templates\glfw.png
btw. i propose to show a MessageBox, if the graphic couldn't be loaded and ignore it
like there is no graphic available instead of emitting a Fatal error and quitting C:B ;-)
mandrav:
Thanks for spotting this :)
File re-uploaded correctly.
--- Quote ---btw. i propose to show a MessageBox, if the graphic couldn't be loaded and ignore it
like there is no graphic available instead of emitting a Fatal error and quitting C:B
--- End quote ---
You see, the problem is that wx uses libpng and it calls png_error() in such cases which uses longjmp() and, in general, doesn't return. It was designed for console-style apps (or you 'd had to register a custom error handler - something that wx should be doing)...
tiwag:
--- Quote from: mandrav ---
--- Quote ---btw. i propose to show a MessageBox, if the graphic couldn't be loaded and ignore it
like there is no graphic available instead of emitting a Fatal error and quitting C:B
--- End quote ---
You see, the problem is that wx uses libpng and it calls png_error() in such cases which uses longjmp() and, in general, doesn't return. It was designed for console-style apps (or you 'd had to register a custom error handler - something that wx should be doing)...
--- End quote ---
shame on me ;-)
i didn't look from where the FatalErr was coming - :shock:
Navigation
[0] Message Index
Go to full version