testsuite: Fix recent GCC FAIL: gdb.arch/i386-signal.exp
[deliverable/binutils-gdb.git] / gdb / amd64-windows-tdep.c
index 1bec6deb92d659b6e98abc00cbc1b3442d4cbb4c..4570622a17b1b303a1a6e951d6ea8ce4cf8d68ed 100644 (file)
@@ -30,6 +30,7 @@
 #include "coff/pe.h"
 #include "libcoff.h"
 #include "value.h"
+#include <algorithm>
 
 /* The registers used to pass integer arguments during a function call.  */
 static int amd64_windows_dummy_call_integer_regs[] =
@@ -141,7 +142,7 @@ amd64_windows_store_arg_in_reg (struct regcache *regcache,
 
   gdb_assert (TYPE_LENGTH (type) <= 8);
   memset (buf, 0, sizeof buf);
-  memcpy (buf, valbuf, min (TYPE_LENGTH (type), 8));
+  memcpy (buf, valbuf, std::min (TYPE_LENGTH (type), (unsigned int) 8));
   regcache_cooked_write (regcache, regno, buf);
 }
 
@@ -1143,7 +1144,7 @@ amd64_windows_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR pc)
       else if (target_read_memory (image_base + unwind_info,
                                   (gdb_byte *) &ex_ui, sizeof (ex_ui)) == 0
               && PEX64_UWI_VERSION (ex_ui.Version_Flags) == 1)
-       return max (pc, image_base + start_rva + ex_ui.SizeOfPrologue);
+       return std::max (pc, image_base + start_rva + ex_ui.SizeOfPrologue);
     }
 
   /* See if we can determine the end of the prologue via the symbol
@@ -1155,7 +1156,7 @@ amd64_windows_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR pc)
        = skip_prologue_using_sal (gdbarch, func_addr);
 
       if (post_prologue_pc != 0)
-       return max (pc, post_prologue_pc);
+       return std::max (pc, post_prologue_pc);
     }
 
   return pc;
This page took 0.025919 seconds and 4 git commands to generate.