gdb/linux-record: Fix newfstatat handling
authorMarcin Kościelnicki <koriakin@0x04.net>
Fri, 30 Oct 2015 15:52:00 +0000 (15:52 +0000)
committerPedro Alves <palves@redhat.com>
Fri, 30 Oct 2015 15:52:00 +0000 (15:52 +0000)
The struct stat pointer is in the third argument, not the second.

gdb/ChangeLog:

* linux-record.c (record_linux_system_call): Fix newstatat.

gdb/ChangeLog
gdb/linux-record.c

index a6d007191a67c20df320cd8a2f6b5b046c91a9df..433ec95c0c363d804946897c8be0046d623fb74f 100644 (file)
@@ -1,3 +1,7 @@
+2015-10-30  Marcin Kościelnicki  <koriakin@0x04.net>
+
+       * linux-record.c (record_linux_system_call): Fix newstatat.
+
 2015-10-30  Marcin Kościelnicki  <koriakin@0x04.net>
 
        * linux-record.c (record_linux_system_call): Fix [gs]etgroups16.
index 25cbda1afcfd1cbb6a544906e8b08076330e2f28..9f38c0b6bd7c8736bbcc601d9043eae8dafb40f1 100644 (file)
@@ -1112,13 +1112,19 @@ Do you want to stop the program?"),
     case gdb_sys_newstat:
     case gdb_sys_newlstat:
     case gdb_sys_newfstat:
-    case gdb_sys_newfstatat:
       regcache_raw_read_unsigned (regcache, tdep->arg2, &tmpulongest);
       if (record_full_arch_list_add_mem ((CORE_ADDR) tmpulongest,
                                         tdep->size_stat))
         return -1;
       break;
 
+    case gdb_sys_newfstatat:
+      regcache_raw_read_unsigned (regcache, tdep->arg3, &tmpulongest);
+      if (record_full_arch_list_add_mem ((CORE_ADDR) tmpulongest,
+                                        tdep->size_stat))
+        return -1;
+      break;
+
     case gdb_sys_uname:
       regcache_raw_read_unsigned (regcache, tdep->arg1, &tmpulongest);
       if (record_full_arch_list_add_mem ((CORE_ADDR) tmpulongest,
This page took 0.034754 seconds and 4 git commands to generate.