Developer forums (C::B DEVELOPMENT STRICTLY!) > Development
Access violation in codeblocks.dll [FIXED]
takeshimiya:
At the time I'm writting this I can't access SF (seems down...), so here it goes:
Steps to reproduce it:
-Add any file (non-mime registered in C::B) to the project.
-Double click on it from within C::B.
-The "What to do?" dialog appears.
-Click on Cancel.
-Access Violation :)
Call stack:
SimpleTextLog::GetTextControl()
src/sdk/simpletextlog.h:20
MessageManager::DebugLogError(char const*, ...)
src/sdk/messagemanager.cpp:232
ProjectManager::DoOpenFile(ProjectFile*, wxString const&)
src/sdk/projectmanager.cpp:1233
ProjectManager::DoOpenSelectedFile()
src/sdk/projectmanager.cpp:1250
ProjectManager::OnProjectFileActivated(wxTreeEvent&)
src/sdk/projectmanager.cpp:1265
When I tried to debug C::B this error doesn't appeared. I'm missing something?
Note: the forum doesn't let me attach *.rpt
[attachment deleted by admin]
rickg22:
From experience, I can tell: Usually there's an non-initialized pointer around.
takeshimiya:
I'm confirming this still happens in SVN HEAD Rev1471.
I want to note that this doesn't happen in RC2, it only displays the expected messagebox:
"ERROR: Could not open file '...'.
No handler registered for this type of file."
Submited the bug report.
mandrav:
--- Quote from: Takeshi Miya on December 08, 2005, 11:33:49 am ---I'm confirming this still happens in SVN HEAD Rev1471.
I want to note that this doesn't happen in RC2, it only displays the expected messagebox:
"ERROR: Could not open file '...'.
No handler registered for this type of file."
Submited the bug report.
--- End quote ---
It works fine here.
According to your bug-report, the backtrace shows:
--- Code: ---MessageManager::DebugLogError(char const*, ...)
src/sdk/messagemanager.cpp:232
ProjectManager::DoOpenFile(ProjectFile*, wxString const&)
src/sdk/projectmanager.cpp:1233
ProjectManager::DoOpenSelectedFile()
src/sdk/projectmanager.cpp:1250
--- End code ---
Line 1250 is blank.
Line 1233 does *not* call MessageManager::DebugLogError().
The code relevant to MIME handling is at line 1241:
--- Code: --- cbMimePlugin* plugin = Manager::Get()->GetPluginManager()->GetMIMEHandlerForFile(filename);
if (!plugin || plugin->OpenFile(filename) != 0) // plugin->OpenFile() returns -1 if you press Cancel
{
wxString msg;
msg.Printf(_("Could not open file '%s'.\nNo handler registered for this type of file."), filename.c_str());
Manager::Get()->GetMessageManager()->DebugLogError(msg);
}
--- End code ---
As you can clearly see, your backtrace has nothing to do with the current HEAD. And I cannot reproduce it because, as you also see, the code is "clean" i.e. has NULL pointer checks etc...
As said above, it works fine here. Make sure you 're using HEAD and not a stickied revision...
mandrav:
@Takeshi Miya: what wx are you using? unicode? ansi?
Navigation
[0] Message Index
[#] Next page
Go to full version