News:

The new Release 25.03 is out! You can download binaries for Windows and many major Linux distros here .

Main Menu

[BUG] Crash after reporting LOOONG compiler errors

Started by Commodore64, June 15, 2007, 04:35:53 PM

Previous topic - Next topic

Commodore64

On Linux (Kubuntu 7.04) when the compiler produces a very long error string, such as the one in the screenshot, C::B crashes almost immediately. The screenshot was taken just a while before the crash!

This is what I get in the command line:

Quote
The program 'codeblocks' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadAlloc (insufficient resources for operation)'.
  (Details: serial 171964 error_code 11 request_code 53 minor_code 0)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the --sync command line
   option to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)

I'm using the latest nightly build, but I've had this problem since I installed C::B on Kubuntu (a couple of months ago). On windows everything seems to work fine.

Thank you, and here it is the screenshot.



Commodore64

Same kind of crash, with the same error, occurs when using the debugger  :?

MortenMacFly

Quote from: Commodore64 on June 15, 2007, 04:35:53 PM
I'm using the latest nightly build, but I've had this problem since I installed C::B on Kubuntu (a couple of months ago). On windows everything seems to work fine.
A piece of code with an error that produces such a long message would be of much help... I don't know how to do so - I don't develop errors... ;-) Can you provide such?
With regards, Morten.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

Commodore64

Quote from: MortenMacFly on June 15, 2007, 05:12:33 PM
A piece of code with an error that produces such a long message would be of much help... I don't know how to do so - I don't develop errors... ;-)
:lol:  :lol:  :lol:

Unfortunately I cannot right now... it is a large library that has not been publicly released yet.

Anyway, I've made a new finding right now. As a gtk+ theme, I was using "Qt" (i.e. the gtk to qt "converter", which is the default gtk+ theme in kubuntu). If I use a "normal" gtk+ theme, instead, the bug disappears. Thus possibly it is not a C::B issue...

Thank you,
Luca

rickg22

There is a way to generate such a long error. Use the #error precompiler directive. :)