diff options
author | Jeff Dike <jdike@addtoit.com> | 2006-09-26 08:33:00 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-09-26 17:49:05 +0200 |
commit | 91b165c0594ab78c64f26d26e3174e6dfd60ed9d (patch) | |
tree | 0730eefa9d4ce786f7f561e3b40700418d6d0970 /arch/um/os-Linux | |
parent | [PATCH] uml: Use klibc setjmp/longjmp (diff) | |
download | linux-91b165c0594ab78c64f26d26e3174e6dfd60ed9d.tar.xz linux-91b165c0594ab78c64f26d26e3174e6dfd60ed9d.zip |
[PATCH] uml: Use ARRAY_SIZE more assiduously
There were a bunch of missed ARRAY_SIZE opportunities.
Also, some formatting fixes in the affected areas of code.
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/um/os-Linux')
-rw-r--r-- | arch/um/os-Linux/mem.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/um/os-Linux/mem.c b/arch/um/os-Linux/mem.c index 560c8063c77c..b170b4704dc4 100644 --- a/arch/um/os-Linux/mem.c +++ b/arch/um/os-Linux/mem.c @@ -114,14 +114,14 @@ static void which_tmpdir(void) } while(1){ - found = next(fd, buf, sizeof(buf) / sizeof(buf[0]), ' '); + found = next(fd, buf, ARRAY_SIZE(buf), ' '); if(found != 1) break; if(!strncmp(buf, "/dev/shm", strlen("/dev/shm"))) goto found; - found = next(fd, buf, sizeof(buf) / sizeof(buf[0]), '\n'); + found = next(fd, buf, ARRAY_SIZE(buf), '\n'); if(found != 1) break; } @@ -135,7 +135,7 @@ err: return; found: - found = next(fd, buf, sizeof(buf) / sizeof(buf[0]), ' '); + found = next(fd, buf, ARRAY_SIZE(buf), ' '); if(found != 1) goto err; |