This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH c++ 03/12] ctf_xfer_partial: Return TARGET_XFER_E_IO instead of -1 on error
- From: Simon Marchi <simon dot marchi at polymtl dot ca>
- To: gdb-patches at sourceware dot org
- Cc: Simon Marchi <simon dot marchi at polymtl dot ca>
- Date: Sun, 25 Oct 2015 23:46:35 -0400
- Subject: [PATCH c++ 03/12] ctf_xfer_partial: Return TARGET_XFER_E_IO instead of -1 on error
- Authentication-results: sourceware.org; auth=none
- References: <1445831204-16588-1-git-send-email-simon dot marchi at polymtl dot ca>
Use the enum value instead of the corresponding int value.
gdb/ChangeLog:
* ctf.c (ctf_xfer_partial): Return TARGET_XFER_E_IO instead of
-1 on error.
---
gdb/ctf.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gdb/ctf.c b/gdb/ctf.c
index cb0d707..b8d7285 100644
--- a/gdb/ctf.c
+++ b/gdb/ctf.c
@@ -1279,7 +1279,7 @@ ctf_xfer_partial (struct target_ops *ops, enum target_object object,
{
/* We're only doing regular memory for now. */
if (object != TARGET_OBJECT_MEMORY)
- return -1;
+ return TARGET_XFER_E_IO;
if (readbuf == NULL)
error (_("ctf_xfer_partial: trace file is read-only"));
--
2.6.2