User forums > Nightly builds

The 19 september 2010 build (6608) DEBUGGER BRANCH version is out.

<< < (2/3) > >>

oBFusCATed:
mushakk: when you have this kind of problems check the modification dates of your files or use touch (unix tool) to fix them

mushakk:
I was modifying a file with Notepad++ and C::B do not detect the file change. Nor when the file was opened inside C::B, nor when it was not opened (C::B do not recompile it).
I don't think was a solvable problem of dates (touch)

Sometimes I have problems with C::B that I solve closing and reopen it.

Max:
Hello devs,

I'm writing to report a bug in the new debugger plugin. Consider the following test case


--- Code: ---
#include <iostream>
#include <string>
#include <wx/wx.h>

int main(int argc, char **argv)
{
   if ( ! ::wxInitialize() ) return -1;

   wxString testString;
   wxString testString2;
   wxString testString3;
   wxString testString4;
   wxString testString5;
   std::string testSTL;

   testString = wxT("AAA     AAA");
   testString2 = wxT("AAA          ");
   testString3 = wxT("AAAA            ");
   testString4 = wxT("            AAAA");
   testString5 = wxT("AAAAAAAAAAAA");
   testSTL = "AAA            ";

   std::cout << testString.mb_str(wxConvUTF8) << std::endl;
   std::cout << testString2.mb_str(wxConvUTF8) << std::endl;
   std::cout << testString3.mb_str(wxConvUTF8) << std::endl;
   std::cout << testString4.mb_str(wxConvUTF8) << std::endl;
   std::cout << testString5.mb_str(wxConvUTF8) << std::endl;
   std::cout << testSTL.c_str() << std::endl;

  return 0;
}


--- End code ---


Compile it (Windows XP SP3,MINGW using GCC 4.5.0, latest packages and GDB 7.2) and start a debug session after setting a breakpoint in line 23. Watch all the strings. You can observe some of the wxStrings are shown truncating the repeated character. That's happening if there are more than 9 identical characters repeated.

The debug log said

>>>>>>cb_gdb:
> whatis &testString5
type = wxString *
>>>>>>cb_gdb:
> output /c testString5.m_pchData[0]@((wxStringData*)testString5.m_pchData - 1)->nDataLength
{65 'A' <repeats 12 times>}>>>>>>cb_gdb:

for an incorrect reporting and

> whatis &testString
type = wxString *
>>>>>>cb_gdb:
> output /c testString.m_pchData[0]@((wxStringData*)testString.m_pchData - 1)->nDataLength
{65 'A', 65 'A', 65 'A', 32 ' ', 32 ' ', 32 ' ', 32 ' ', 32 ' ', 65 'A', 65 'A', 65 'A'}>>>>>>cb_gdb:

for a correct one. May be the <repeats 12 times> is the root cause.


The STL string is showing two lines the first with the "AAA" and the second with the ' ' <repeated 12 times>.

I think the expected behavior shuold be just one line with the full string.


Hope this helps

Max

oBFusCATed:
Confirmed and added to my TODO

Max:
oBFusCATed ,

Any chance to have this bug fixed?

Thx.

Max

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version