summary refs log tree commit diff
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2017-11-30 16:33:59 -0800
committerH.J. Lu <hjl.tools@gmail.com>2017-11-30 16:34:09 -0800
commitef5d8b4342dbeeb6b9e67df75c89251898150532 (patch)
tree1e464a21885f1694f628699cf3cd954b4bfb67e4
parentf938b397dd17265a1a005cd5786f197de1013e74 (diff)
downloadglibc-ef5d8b4342dbeeb6b9e67df75c89251898150532.tar.gz
glibc-ef5d8b4342dbeeb6b9e67df75c89251898150532.tar.xz
glibc-ef5d8b4342dbeeb6b9e67df75c89251898150532.zip
mips: Don't use MIN in dl-machine.h
MIN is used, but param.h may not be included, so expand its single use
inline.

	* sysdeps/mips/dl-machine.h (elf_machine_reloc): Expand MIN.
-rw-r--r--ChangeLog4
-rw-r--r--sysdeps/mips/dl-machine.h3
2 files changed, 6 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 9f842e7b26..fc0bd3e94b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2017-11-30  H.J. Lu  <hongjiu.lu@intel.com>
+
+	* sysdeps/mips/dl-machine.h (elf_machine_reloc): Expand MIN.
+
 2017-11-30  Joseph Myers  <joseph@codesourcery.com>
 
 	* sysdeps/m68k/coldfire/fpu/s_fabsf.c: Include
diff --git a/sysdeps/mips/dl-machine.h b/sysdeps/mips/dl-machine.h
index da9d6332ea..904824b908 100644
--- a/sysdeps/mips/dl-machine.h
+++ b/sysdeps/mips/dl-machine.h
@@ -695,7 +695,8 @@ elf_machine_reloc (struct link_map *map, ElfW(Addr) r_info,
 			      RTLD_PROGNAME, strtab + refsym->st_name);
 	  }
 	memcpy (reloc_addr, (void *) value,
-		MIN (sym->st_size, refsym->st_size));
+		sym->st_size < refsym->st_size
+		? sym->st_size : refsym->st_size);
 	break;
       }