This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFA] arm-tdep.c: deal with failed memory read
- From: Elena Zannoni <ezannoni at cygnus dot com>
- To: Andrew Cagney <ac131313 at cygnus dot com>
- Cc: Elena Zannoni <ezannoni at cygnus dot com>, Fernando Nasser <fnasser at cygnus dot com>, gdb-patches at sources dot redhat dot com
- Date: Wed, 19 Dec 2001 18:07:47 -0500
- Subject: Re: [RFA] arm-tdep.c: deal with failed memory read
- References: <15356.17915.602742.140302@krustylu.cygnus.com><3BFEB3EB.816139A1@cygnus.com><3C04615A.7020304@cygnus.com><3C054819.30605@cygnus.com>
Andrew Cagney writes:
> > The arm-tdep.c part is approved.
> >
> > We desperatly need a better naming convention and clearer semantics (what happens if the function fails due to a target disconnect) for these wrapped functions. gdb_*() is being used by both libgdb and wrapper.[hc] et.al.
>
> Hmm, this doesn't read very well. Lets try ...
>
> gdb.h contains gdb_...() libgdb functions.
>
> wrapper.h contains gdb_...() save functions.
>
> Two very different interfaces with identical prefixes. I think a
> separate naming convention needs to be adopted for save / wrapped / ...
> functions. I also think the function semantics need to be more tightly
> defined. For instance, a safe function should catch a bad memory read,
> should that safe function catch a failure because the target interface
> has gone down (tcp connection lost, ...) or because the user entered a
> cntrl-c.
>
> Anyway, food for thought.
>
> enjoy,
> Andrew
>
I committed the patch and changed the name from gdb_read_memory_integer
to safe_read_memory_integer.
I haven't committed it to the 5.1 branch, should I?.
Elena