I can confirm this.
Here's a patch that fixes this issue:
--- codeblocks-1.0svn.orig/src/sdk/cbproject.cpp 2008-03-10 17:55:06.000000000 +0100
+++ codeblocks-1.0svn.work/src/sdk/cbproject.cpp 2008-04-02 23:00:01.000000000 +0200
@@ -1226,6 +1226,8 @@
SetModified(true);
+ Manager::Get()->GetProjectManager()->RebuildTree();
+
return true;
}
Will look into this today. :)
Hi Biplab,
the crash happens in line 280 in "projectfile.cpp" when the new image should be set in the tree after changing the files content.
tree->SetItemImage(m_TreeItemId, (int)state, wxTreeItemIcon_Normal);
"m_TreeItemId" only gets set when the tree is build (or rebuild), so I think it's invalid after dragging the node.
The crash does not appear when the project is saved before editing (after saving the project, C::B does a rebuild of the tree).
So I think the easiest way is to rebuild the tree after dragging is completed.
Another solution would be to renew "m_TreeItemId" only, but I haven't got the time to figure out the right place for doing this, so I went the easy way.