|
From: Shane B. <ast...@te...> - 2003-07-14 20:14:33
|
GCC is the GNU compiler collection, it includes front ends for C, C++, ADA,
Fortran and some others as I recall. GDB, is the GNU debugger. It is a
commandline debugging utility, commonly used on unix based systems. If
you've ever added -g (or -ggdb), you're adding debugging code that GDB uses
for debugging. Comparative to Win32 DEBUG versus RELEASE compilations on
VC++. GDB itself, I used mostly for tracing crash's and viewing memory.
This is how I've determined that the crash occurs when trying to access an
invalid pointer. When it breaks out into GDB in the crash, it leaves me at
a "map::find" statement, which, when I step into it, I find that the key (an
std::string) is valid, but the data portion, a pointer to an allocated User,
is somehow fubar'd, because if I try to print (no different than getting the
value of a variable in VC++ debugger) the pointer, GDB itself will indicate
that the program crashed while attempting to execute something by GDB. This
means that 1) the code crashes and drops me into the debugger, and 2) it is
in fact crashing because of the variable value, as executing the single
operation of printing the value causes an internal crash that GDB recovers
from, but ends execution of the program.
The problem I am seeing, I have never seen in all my time programming, and I
have a good 8 years background with C. Further issues with this, may result
in me reverting UserList to a true linked list implementation, instead of
STL, which could be the culprit even though I don't want to blame it. Even
reverting temporarily to a C linked list may help me in travelling the list
in the debugger to find out where the problem is (like if it's the last or
first element, etc)... Short of testing my new changes, this will be the
next step, to revert to a very slow and simple linked list until I can track
down the problem. At least I have some direction, I appreciate the help
everyone has offered.
Sincerely,
-Shane
p.s. http://www.gnu.org/software/gdb, for all the information you want on
GDB.
----- Original Message -----
From: "Hossein Haeri" <ult...@em...>
To: <dev...@li...>
Sent: Monday, July 14, 2003 10:39 AM
Subject: RE: [Dev-C++] STL Map question
> Dear Ioannis,
>
> > Keep in mind that there is the mailing list archive on line (which is
> > unfortunately 12/24h behind but anyway):
> >
> > http://sourceforge.net/mailarchive/forum.php?forum=dev-cpp-users
>
> Thanks! It was quite useful. Furthermore, I didn't know the address of
> the page. Thank you very much indeed.
>
> And about the compiler: I found out that you had mentioned its name as
> "GDB". And that's what I haven't ever heard about, and not GCC. Now,
> may I ask what it stands for?
>
> Thanks,
> --Hossein
>
> --
> __________________________________________________________
> Sign-up for your own FREE Personalized E-mail at Mail.com
> http://www.mail.com/?sr=signup
>
> CareerBuilder.com has over 400,000 jobs. Be smarter about your job search
> http://corp.mail.com/careers
>
>
>
> -------------------------------------------------------
> This SF.Net email sponsored by: Parasoft
> Error proof Web apps, automate testing & more.
> Download & eval WebKing and get a free book.
> www.parasoft.com/bulletproofapps1
> _______________________________________________
> Dev-cpp-users mailing list
> Dev...@li...
> TO UNSUBSCRIBE: http://www23.brinkster.com/noicys/devcpp/ub.htm
> https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
|