diff options
author | 2004-09-14 22:19:30 +0000 | |
---|---|---|
committer | 2004-09-14 22:19:30 +0000 | |
commit | 1b24ffd02cc7f92e472706f4a9b7e625b82d1faa (patch) | |
tree | 14993f89fadbdfd368623e68ddcbcebaa77111d8 /lib/libc/sys/stack_protector.c | |
parent | ansi (diff) | |
download | wireguard-openbsd-1b24ffd02cc7f92e472706f4a9b7e625b82d1faa.tar.xz wireguard-openbsd-1b24ffd02cc7f92e472706f4a9b7e625b82d1faa.zip |
lint says unsigned...
Diffstat (limited to 'lib/libc/sys/stack_protector.c')
-rw-r--r-- | lib/libc/sys/stack_protector.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/libc/sys/stack_protector.c b/lib/libc/sys/stack_protector.c index 7e6746f7128..2379b955993 100644 --- a/lib/libc/sys/stack_protector.c +++ b/lib/libc/sys/stack_protector.c @@ -1,4 +1,4 @@ -/* $OpenBSD: stack_protector.c,v 1.6 2003/10/01 18:19:08 miod Exp $ */ +/* $OpenBSD: stack_protector.c,v 1.7 2004/09/14 22:19:30 deraadt Exp $ */ /* * Copyright (c) 2002 Hiroaki Etoh, Federico G. Schwindt, and Miodrag Vallat. @@ -28,7 +28,7 @@ */ #if defined(LIBC_SCCS) && !defined(list) -static char rcsid[] = "$OpenBSD: stack_protector.c,v 1.6 2003/10/01 18:19:08 miod Exp $"; +static char rcsid[] = "$OpenBSD: stack_protector.c,v 1.7 2004/09/14 22:19:30 deraadt Exp $"; #endif #include <sys/param.h> @@ -65,8 +65,10 @@ __guard_setup(void) if (i < sizeof(__guard) / 4) { /* If sysctl was unsuccessful, use the "terminator canary". */ - ((char *)__guard)[0] = 0; ((char*)__guard)[1] = 0; - ((char *)__guard)[2] = '\n'; ((char *)__guard)[3] = 255; + ((unsigned char *)__guard)[0] = 0; + ((unsigned char *)__guard)[1] = 0; + ((unsigned char *)__guard)[2] = '\n'; + ((unsigned char *)__guard)[3] = 255; } } |