From: "H.J. Lu" <hjl.tools@gmail.com>
To: Binutils <binutils@sourceware.org>, GDB <gdb-patches@sourceware.org>
Subject: Re: PATCH: PR binutils/14813: Wrong return type for opncls_bclose
Date: Wed, 07 Nov 2012 05:34:00 -0000 [thread overview]
Message-ID: <CAMe9rOrq7QNfMk6cBtN37TtNHCo-wQ83CbNM9r1GsHqsB8qWCg@mail.gmail.com> (raw)
In-Reply-To: <20121107010714.GQ31965@bubble.grove.modra.org>
On Tue, Nov 6, 2012 at 5:07 PM, Alan Modra <amodra@gmail.com> wrote:
> On Tue, Nov 06, 2012 at 04:30:07PM -0800, H.J. Lu wrote:
>> Hi,
>>
>> This patch changes return type of bclose to bfd_boolean. It fixes
>> binutils/bfdtest2. OK to install?
>
> Not without checking gdb code too.
>
Sure. Here is the GDB patch. OK to install?
--
H.J.
---
2012-11-06 H.J. Lu <hongjiu.lu@intel.com>
* jit.c (mem_bfd_iovec_close): Change return type to bfd_boolean.
* remote.c (remote_bfd_iovec_close): Likewise.
* solib-spu.c (spu_bfd_iovec_close): Likewise.
* spu-linux-nat.c (bfd_boolean): Likewise.
diff --git a/gdb/jit.c b/gdb/jit.c
index 9e8f295..98a92a3 100644
--- a/gdb/jit.c
+++ b/gdb/jit.c
@@ -85,11 +85,11 @@ mem_bfd_iovec_open (struct bfd *abfd, void *open_closure)
/* Closing the file is just freeing the base/size pair on our side. */
-static int
+static bfd_boolean
mem_bfd_iovec_close (struct bfd *abfd, void *stream)
{
xfree (stream);
- return 1;
+ return TRUE;
}
/* For reading the file, we just need to pass through to target_read_memory and
diff --git a/gdb/remote.c b/gdb/remote.c
index 24bb9bc..0af4265 100644
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -9774,7 +9774,7 @@ remote_bfd_iovec_open (struct bfd *abfd, void
*open_closure)
return stream;
}
-static int
+static bfd_boolean
remote_bfd_iovec_close (struct bfd *abfd, void *stream)
{
int fd = *(int *)stream;
@@ -9786,7 +9786,7 @@ remote_bfd_iovec_close (struct bfd *abfd, void *stream)
connection was already torn down. */
remote_hostio_close (fd, &remote_errno);
- return 1;
+ return TRUE;
}
static file_ptr
diff --git a/gdb/solib-spu.c b/gdb/solib-spu.c
index f62d96c..1c4f450 100644
--- a/gdb/solib-spu.c
+++ b/gdb/solib-spu.c
@@ -282,11 +282,11 @@ spu_bfd_iovec_open (bfd *nbfd, void *open_closure)
return open_closure;
}
-static int
+static bfd_boolean
spu_bfd_iovec_close (bfd *nbfd, void *stream)
{
xfree (stream);
- return 1;
+ return TRUE;
}
static file_ptr
diff --git a/gdb/spu-linux-nat.c b/gdb/spu-linux-nat.c
index 1932aae..5d2f752 100644
--- a/gdb/spu-linux-nat.c
+++ b/gdb/spu-linux-nat.c
@@ -273,11 +273,11 @@ spu_bfd_iovec_open (struct bfd *nbfd, void *open_closure)
return open_closure;
}
-static int
+static bfd_boolean
spu_bfd_iovec_close (struct bfd *nbfd, void *stream)
{
xfree (stream);
- return 1;
+ return TRUE;
}
static file_ptr
next parent reply other threads:[~2012-11-07 5:34 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20121107003007.GA8682@gmail.com>
[not found] ` <20121107010714.GQ31965@bubble.grove.modra.org>
2012-11-07 5:34 ` H.J. Lu [this message]
2012-11-07 7:31 ` Alan Modra
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAMe9rOrq7QNfMk6cBtN37TtNHCo-wQ83CbNM9r1GsHqsB8qWCg@mail.gmail.com \
--to=hjl.tools@gmail.com \
--cc=binutils@sourceware.org \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox