diff options
author | Elliott Hughes <enh@google.com> | 2014-01-16 10:53:11 -0800 |
---|---|---|
committer | Elliott Hughes <enh@google.com> | 2014-01-16 12:54:18 -0800 |
commit | ccecf1425412beb2bc3bb38d470293fdc244d6f1 (patch) | |
tree | 9fd922197bc88bed453efa0738f3dfb5d6db4c3c /toolbox/insmod.c | |
parent | e847f429f43ae56aaa406697ca603c8469e2100b (diff) | |
download | system_core-ccecf1425412beb2bc3bb38d470293fdc244d6f1.zip system_core-ccecf1425412beb2bc3bb38d470293fdc244d6f1.tar.gz system_core-ccecf1425412beb2bc3bb38d470293fdc244d6f1.tar.bz2 |
system/core 64-bit cleanup.
This cleans up most of the size-related problems in system/core.
There are still a few changes needed for a clean 64-bit build,
but they look like they might require changes to things like the
fastboot protocol.
Change-Id: I1560425a289fa158e13e2e3173cc3e71976f92c0
Diffstat (limited to 'toolbox/insmod.c')
-rw-r--r-- | toolbox/insmod.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/toolbox/insmod.c b/toolbox/insmod.c index 756a64b..fb1448b 100644 --- a/toolbox/insmod.c +++ b/toolbox/insmod.c @@ -4,6 +4,7 @@ #include <unistd.h> #include <malloc.h> #include <errno.h> +#include <sys/param.h> #include <sys/types.h> #include <sys/stat.h> #include <unistd.h> @@ -45,7 +46,6 @@ bail: return buffer; } -#define min(x,y) ((x) < (y) ? (x) : (y)) int insmod_main(int argc, char **argv) { void *file; @@ -73,7 +73,7 @@ int insmod_main(int argc, char **argv) char *ptr = opts; for (i = 2; (i < argc) && (ptr < end); i++) { - len = min(strlen(argv[i]), end - ptr); + len = MIN(strlen(argv[i]), end - ptr); memcpy(ptr, argv[i], len); ptr += len; *ptr++ = ' '; |