Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: LETARTARE on March 21, 2012, 11:00:52 am

Title: CRASH CB with a text file
Post by: LETARTARE on March 21, 2012, 11:00:52 am
from http://forums.codeblocks.org/index.php?PHPSESSID=tofb9t8sn4c8i7a670rkq2a4f5&topic=1022.msg108685#msg108685 (http://forums.codeblocks.org/index.php?PHPSESSID=tofb9t8sn4c8i7a670rkq2a4f5&topic=1022.msg108685#msg108685)
I get the file 'All_codeblocks_fr_7900.7z'
Then I load the file 'All_codeblocks.po' (1346448 bytes) in the editor of 'C::B' (or any file of the same size)
This file is encoded in UTF-8 with 'EOL' = 'LF'
The editor uses 'EOL' = 'CRLF'.
if I backup after a change, 'C::B' crashes with the following error message:

I repeated this operation several times, it seems that the file size is the reason for the crash.
Title: Re: CRASH CB with a text file
Post by: Jenna on March 21, 2012, 02:16:21 pm
Try to uncheck "Settings -> Editor -> Margins and caret -> Use changebar".

I know, that C:B can crash with very many changes tracked for the changebar, but i did not find the time to look into it deeper.
Title: Re: CRASH CB with a text file
Post by: LETARTARE on March 21, 2012, 02:22:43 pm
yes, it works well !!!!
it is not intuitive.
is there a limit on file size ?
Well thank you Jens
Title: Re: CRASH CB with a text file
Post by: Jenna on March 21, 2012, 03:08:32 pm
yes, it works well !!!!
it is not intuitive.
is there a limit on file size ?
Well thank you Jens

No limit in file size, but the changebar implementation seems to run out of memory for too many changes.
As written before, I digged not into it deeper, but will do, if I find the time.
It needs about 50k changed lines to crash, and that is really large.
Title: Re: CRASH CB with a text file
Post by: MortenMacFly on March 22, 2012, 02:44:51 pm
As written before, I digged not into it deeper, but will do, if I find the time.
Not sure, if you need this. On Windows, with recent wxScintilla (3.0.4) of my working copy it works just fine. I couldn't make is crash the ways as described, even with massive changes. Maybe it was a bug in the scintilla version we are using currently.
Title: Re: CRASH CB with a text file
Post by: LETARTARE on March 22, 2012, 02:51:06 pm
What should I do to use wxScintilla version (3.0.4)  on 'C::B r7900' ?
Title: Re: CRASH CB with a text file
Post by: oBFusCATed on March 22, 2012, 02:54:58 pm
Wait for Morten to update it :)
Title: Re: CRASH CB with a text file
Post by: MortenMacFly on March 22, 2012, 08:32:05 pm
Wait for Morten to update it :)
I won't, because it breaks the debugger branch. The PNG images you are using for BP markers will not work in combination with scintilla default ones, like bookmarks. Everything else is fine.
Title: Re: CRASH CB with a text file
Post by: oBFusCATed on March 22, 2012, 10:31:18 pm
Grrr, do we have to migrate to all png solution?
Have you reported this? Do they intend to fix it?
Title: Re: CRASH CB with a text file
Post by: MortenMacFly on March 23, 2012, 08:05:05 am
Grrr, do we have to migrate to all png solution?
Best would be if we stick with the default ones.

Have you reported this? Do they intend to fix it?
Yes, but as I didn't find the time to produce a minimal sample to reproduce and it works in SciTE the bug was closed immediately. So it may also be an issue in the wx part of wxScintilla. Then its our duty.
Title: Re: CRASH CB with a text file
Post by: oBFusCATed on March 23, 2012, 09:03:06 am
Best would be if we stick with the default ones.
I like the png's, they look more modern.

Yes, but as I didn't find the time to produce a minimal sample to reproduce and it works in SciTE the bug was closed immediately. So it may also be an issue in the wx part of wxScintilla. Then its our duty.
Can you give me a patch, so I can test it?