Developer forums (C::B DEVELOPMENT STRICTLY!) > CodeCompletion redesign

Crash after opening an XPM file.

<< < (2/3) > >>

danselmi:
Updated to r6771, still crashes after opening an xpm file.
I attached a XPM file and the call-stack (gdb 7.2) from the crash.

danselmi:
So it must not be a xpm! A simple txt will do to give a crash if the file does not belong to a project. (Jens, the xpm you tried is from an open project, right?) The following patch stops cb crashing:

--- Code: ---Index: nativeparser.cpp
===================================================================
--- nativeparser.cpp (revision 6773)
+++ nativeparser.cpp (working copy)
@@ -3368,7 +3368,7 @@
         SwitchParser(project, parser);
     }
 
-    if (m_ClassBrowser && parser->ClassBrowserOptions().displayFilter == bdfFile)
+    if (m_ClassBrowser && parser && parser->ClassBrowserOptions().displayFilter == bdfFile)
     {
         // check header and implementation file swap, if yes, don't need to rebuild browser tree
         m_ClassBrowser->UpdateView(true);

--- End code ---
Don't know if it is the right way!

The other thing is that: IMHO an xpm should be parsed.

Jenna:
Yes it was in a project.
It crashes witha a single xpm or with another file, that is not a source or header-file, sources or headers are parsed correctly.

MortenMacFly:

--- Quote from: danselmi on October 27, 2010, 09:20:02 pm ---The other thing is that: IMHO an xpm should be parsed.

--- End quote ---
Isn't that the case if you put the XPM extension under C/C++ source files?

danselmi:

--- Quote from: MortenMacFly on October 27, 2010, 09:37:01 pm ---
--- Quote from: danselmi on October 27, 2010, 09:20:02 pm ---The other thing is that: IMHO an xpm should be parsed.

--- End quote ---
Isn't that the case if you put the XPM extension under C/C++ source files?

--- End quote ---
I just tried: xpms are highlighted now, but CC doesn't know the name (xy_xpm) of the string.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version