Code::Blocks Forums

Developer forums (C::B DEVELOPMENT STRICTLY!) => Plugins development => Topic started by: damorin on June 21, 2011, 09:47:57 pm

Title: cscope plugin not supporting space in project name (Win32)
Post by: damorin on June 21, 2011, 09:47:57 pm
Hi,

just to report a small bug in the cscope plugin. It's working fine as long as the path is not containing space (not like this one "c:\users\rmorin\fx-2000\fx-2000 Phase II").

Any work-around for this one ?

Thanks.

Windows XP with C:B SVN 7075.

Title: Re: cscope plugin not supporting space in project name (Win32)
Post by: MortenMacFly on June 23, 2011, 08:31:00 am
Any work-around for this one ?
If you are willing to patch, in CscopePligin.cpp, the method void CscopePlugin::OnFind(wxCommandEvent &event), replacing this line:
Code
    cmd += WordAtCaret + _T(" -i ") + list_file;
...with this:
Code
    cmd += WordAtCaret + _T(" -i \"") + list_file + _T("\"");
...should do the trick.