Extract string-printing out of ada_val_print_array
[deliverable/binutils-gdb.git] / gdb / i386-windows-nat.c
index 5d93915a72a953ad9467c8bbcfb9675e9048106f..caa645a9e50c24b4849910dd8d76b22a208d04d4 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 2008-2012 Free Software Foundation, Inc.
+/* Copyright (C) 2008-2014 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -18,6 +18,7 @@
 #include "defs.h"
 #include "windows-nat.h"
 #include "i386-nat.h"
+#include "i386-tdep.h"
 
 #include <windows.h>
 
@@ -70,6 +71,14 @@ static const int mappings[] =
 };
 #undef context_offset
 
+/* segment_register_p_ftype implementation for x86.  */
+
+static int
+i386_windows_segment_register_p (int regnum)
+{
+  return regnum >= I386_CS_REGNUM && regnum <= I386_GS_REGNUM;
+}
+
 /* -Wmissing-prototypes */
 extern initialize_file_ftype _initialize_i386_windows_nat;
 
@@ -77,5 +86,6 @@ void
 _initialize_i386_windows_nat (void)
 {
   windows_set_context_register_offsets (mappings);
+  windows_set_segment_register_p (i386_windows_segment_register_p);
   i386_set_debug_register_length (4);
 }
This page took 0.023617 seconds and 4 git commands to generate.