I've been doing a lot of 'low memory' testing lately, and I've gotten a crash to occur in SciLexer
(The crash occurs in SciLexer)
(It crashed using a a fresh cvs copy of SciLexer.dll, compiled with msvc++ v6 on windows 98...)

(By low memory testing, I mean allocating more or less all of the memory I have on this pc and then running the application, opening documents until it crashes.)

The code I have that crashes it, basically just adds text to the document (from a file)...

Which looks like this:

/////////////

while (!feof(file))
{
 char buffer[4096] = {0};
 int read_size = fread(buffer, sizeof(char), 4096, file);
 if (read_size > 0) {
   SendEditor(SCI_ADDTEXT, read_size, (LPARAM)buffer);
   total_read += read_size;
 }
sprintf (status_text, "%d%%...", (int)(((double)total_read / (double)file_size) * 100));
 GetStatusBar()->SetWindowText(status_text);
}

/////////////

With SendEditor being the way I send commands to SciLexer.

Has anyone else noticed problems like this?

_________________________________________________________________
Windows LiveĀ™ Messenger has arrived. Click here to download it for free! http://imagine-msn.com/messenger/launch80/?locale=en-gb

_______________________________________________
Scintilla-interest mailing list
[email protected]
http://mailman.lyra.org/mailman/listinfo/scintilla-interest

Reply via email to