Developer forums (C::B DEVELOPMENT STRICTLY!) > Development
Error when adding a new file (to a project)
thomas:
I have found at least two illegal keys, although those are not likely the ones causing this particular error.
rickg22:
I got an idea... why not use regedit and search for all the offending keys?
thomas:
I have been searching for printf, because many offending keys are generated like this:
some_string.Printf("/some/path/%d", integer)
I have also been searching for _T("editor") in order to find all places where that namespace is being used, but that did not reveal anything.
I really wish there was something like __FILE__, __LINE__, or __FUNCTION__ which we could use. But we would need something like __CALLING_FUNCTION__.
I don't know of any such thing, is there? If there is, I could just add it to the exception, and you would know *exactly* where to look.
EDIT:
Never mind, backtrace will do too...
Lamego:
Here is a backtrace of the crash on linux:
...
#5 0xb7744f11 in std::terminate () from /usr/lib/libstdc++.so.6
#6 0xb774509c in __cxa_throw () from /usr/lib/libstdc++.so.6
#7 0xb7e2c46c in ConfigManager::AssertPath (this=0x83377c8, path=@0xbfca01ac)
at configmanager.cpp:504
#8 0xb7e2d843 in ConfigManager::Read (this=0x83377c8, name=@0xbfca024c,
str=0xbfca01f8) at configmanager.cpp:644
#9 0xb7e2da40 in ConfigManager::Read (this=0x83377c8, name=@0xbfca024c,
defaultVal=@0xbfca0254) at configmanager.cpp:624
#10 0xb7e59960 in EditorManager::New (this=0x8335d88) at editormanager.cpp:689
...
--- Code: ---643 wxString key(name);
644 TiXmlElement* e = AssertPath(key);
645
646 TiXmlHandle parentHandle(e);
647 TiXmlText *t = (TiXmlText *) parentHandle.FirstChild(_C(key)).FirstC hild("str").FirstChild().Node();
648
--- End code ---
(gdb) p name
$2 = (const wxString &) @0xbfca024c: {<wxStringBase> = {
static npos = 4294967295,
m_pchData = 0x8c7ad5c "/default_code/7"}, <No data fields>}
Ceniza:
Instead of "/default_code/7" it should say "/default_code/set7". I just found it in Windows too.
Just searched for "default_code" in all project files and found 3 wrongly set.
It seems like this bug is dying now...
Just changed those offending keys and it's working!!!
editorconfigurationdialog.cpp lines 532 and 536
editormanager.cpp line 688
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version