]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
ctf_xfer_partial: Return TARGET_XFER_E_IO instead of -1 on error
authorSimon Marchi <simon.marchi@polymtl.ca>
Tue, 27 Oct 2015 02:00:41 +0000 (22:00 -0400)
committerSimon Marchi <simon.marchi@polymtl.ca>
Tue, 27 Oct 2015 02:01:45 +0000 (22:01 -0400)
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/ChangeLog
gdb/ctf.c

index a481f0997415d6473b149cc24aa9aab15d7573d2..a063a049015a81ec46b4c64404c7109cb461a9c8 100644 (file)
@@ -1,3 +1,8 @@
+2015-10-26  Simon Marchi  <simon.marchi@polymtl.ca>
+
+       * ctf.c (ctf_xfer_partial): Return TARGET_XFER_E_IO instead of
+       -1 on error.
+
 2015-10-26  Doug Evans  <dje@google.com>
 
        PR symtab/17391
index 6c1aedea75718568683006f76f38ec5cd82fe04b..dc378d184b4dd2ce306f86df020cea3313487a06 100644 (file)
--- a/gdb/ctf.c
+++ b/gdb/ctf.c
@@ -1273,7 +1273,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"));