This is the mail archive of the
gdb-cvs@sourceware.org
mailing list for the GDB project.
[binutils-gdb] Make remote file transfers interruptible
- From: Gary Benson <gary at sourceware dot org>
- To: gdb-cvs at sourceware dot org
- Date: 21 Aug 2015 16:14:57 -0000
- Subject: [binutils-gdb] Make remote file transfers interruptible
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=2d7711a36720b0bc44fee20d0bf057614ead21c2
commit 2d7711a36720b0bc44fee20d0bf057614ead21c2
Author: Gary Benson <gbenson@redhat.com>
Date: Fri Aug 21 17:10:24 2015 +0100
Make remote file transfers interruptible
This commit makes it possible to interrupt remote file transfers.
Diff:
---
gdb/ChangeLog | 4 ++++
gdb/gdb_bfd.c | 2 ++
2 files changed, 6 insertions(+)
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index d8b23e0..f5dd5f3 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,9 @@
2015-08-21 Gary Benson <gbenson@redhat.com>
+ * gdb_bfd.c (gdb_bfd_iovec_fileio_pread): Add QUIT call.
+
+2015-08-21 Gary Benson <gbenson@redhat.com>
+
* target.h (struct target_ops) <to_fileio_open>: New argument
warn_if_slow. Update comment. All implementations updated.
(target_fileio_open_warn_if_slow): New declaration.
diff --git a/gdb/gdb_bfd.c b/gdb/gdb_bfd.c
index bffe589..64712da 100644
--- a/gdb/gdb_bfd.c
+++ b/gdb/gdb_bfd.c
@@ -292,6 +292,8 @@ gdb_bfd_iovec_fileio_pread (struct bfd *abfd, void *stream, void *buf,
pos = 0;
while (nbytes > pos)
{
+ QUIT;
+
bytes = target_fileio_pread (fd, (gdb_byte *) buf + pos,
nbytes - pos, offset + pos,
&target_errno);