This is the mail archive of the
insight@sources.redhat.com
mailing list for the Insight project.
Re: [RFA] Insight fix for missing tick marks.
- To: "John R. Moore" <jmoore at redhat dot com>
- Subject: Re: [RFA] Insight fix for missing tick marks.
- From: Fernando Nasser <fnasser at cygnus dot com>
- Date: Wed, 28 Mar 2001 13:12:14 -0500
- CC: insight at sources dot redhat dot com
- Organization: Red Hat , Inc. - Toronto
- References: <Pine.LNX.4.33.0103280946440.26014-100000@bosch.cygnus.com>
John,
Can you please add a comment before the test explaining when that situation (i.e. nitems == 0) can happen.
Thanks.
Fernando
"John R. Moore" wrote:
>
> The following was tested on Linux using latest branch for gcc
> on RedHat 7 with kernels 2.2.16 and 2.4.2.
>
> 2001-03-28 John R. Moore <jmoore@cygnus.com>
>
> * gdbtk-cmds.c (full_lookup_symtab): Check for non-zero
> nitems in selecting symtab in addition to matching just
> fullname.
>
> Index: gdb/gdbtk/generic/gdbtk-cmds.c
> ===================================================================
> RCS file: /cvs/cvsfiles/devo/gdb/gdbtk/generic/gdbtk-cmds.c,v
> retrieving revision 1.17
> diff -p -u -r1.17 gdbtk-cmds.c
> --- gdb/gdbtk/generic/gdbtk-cmds.c 2001/03/26 19:55:12 1.17
> +++ gdb/gdbtk/generic/gdbtk-cmds.c 2001/03/28 17:27:25
> @@ -4696,7 +4696,7 @@ full_lookup_symtab (file)
> else
> fullname = st->fullname;
>
> - if (!strcmp (file, fullname))
> + if (st->linetable->nitems > 0 && !strcmp (file, fullname))
> return st;
> }
> }
> @@ -4710,7 +4710,7 @@ full_lookup_symtab (file)
> if (st)
> {
> fullname = symtab_to_filename (st);
> - if (!strcmp (file, fullname))
> + if (st->linetable->nitems > 0 && !strcmp (file, fullname))
> return st;
> }
> }
--
Fernando Nasser
Red Hat - Toronto E-Mail: fnasser@redhat.com
2323 Yonge Street, Suite #300
Toronto, Ontario M4P 2C9