1
0
Fork 0

[PATCH] uml: fix min usage

type-safe min() in arch/um/drivers/mconsole_kern.c

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
hifive-unleashed-5.1
Al Viro 2006-03-31 02:30:17 -08:00 committed by Linus Torvalds
parent 43cecb3079
commit e11c0cdf4c
1 changed files with 1 additions and 1 deletions

View File

@ -616,7 +616,7 @@ static void console_write(struct console *console, const char *string,
return;
while(1){
n = min(len, ARRAY_SIZE(console_buf) - console_index);
n = min((size_t)len, ARRAY_SIZE(console_buf) - console_index);
strncpy(&console_buf[console_index], string, n);
console_index += n;
string += n;