diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-06-01 17:00:41 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-06-01 17:00:41 +0000 |
commit | 173d01b7c1e9a5d7ba5a6c696a8019061dc41bda (patch) | |
tree | 8c8b7bb08108dca24afcee3bbe301e8ba6f76e81 /sys/arch/sparc | |
parent | 3e42965de9054a39afc4957c4f099218e709ae51 (diff) |
strcpy/strcat/sprintf removal in all bootblocks. various testing by
various people. outside of some messy things in src/gnu, only one
thing in the main tree now violates this rule: bind
Diffstat (limited to 'sys/arch/sparc')
-rw-r--r-- | sys/arch/sparc/stand/common/promdev.c | 4 | ||||
-rw-r--r-- | sys/arch/sparc/stand/libkern/Makefile | 6 | ||||
-rw-r--r-- | sys/arch/sparc/stand/libsa/Makefile | 4 |
3 files changed, 7 insertions, 7 deletions
diff --git a/sys/arch/sparc/stand/common/promdev.c b/sys/arch/sparc/stand/common/promdev.c index 54ae9041910..719c162e818 100644 --- a/sys/arch/sparc/stand/common/promdev.c +++ b/sys/arch/sparc/stand/common/promdev.c @@ -1,4 +1,4 @@ -/* $OpenBSD: promdev.c,v 1.7 2002/08/15 15:41:35 millert Exp $ */ +/* $OpenBSD: promdev.c,v 1.8 2003/06/01 17:00:39 deraadt Exp $ */ /* $NetBSD: promdev.c,v 1.16 1995/11/14 15:04:01 pk Exp $ */ /* @@ -534,7 +534,7 @@ prom_getether(fd, ea) (void)(*promvec->pv_enaddr)(fd, (char *)ea); } else { char buf[64]; - sprintf(buf, "%x mac-address drop swap 6 cmove", ea); + snprintf(buf, sizeof buf, "%x mac-address drop swap 6 cmove", ea); promvec->pv_fortheval.v2_eval(buf); } } diff --git a/sys/arch/sparc/stand/libkern/Makefile b/sys/arch/sparc/stand/libkern/Makefile index 594e0c0da47..d739830daef 100644 --- a/sys/arch/sparc/stand/libkern/Makefile +++ b/sys/arch/sparc/stand/libkern/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.2 1999/12/10 10:40:47 deraadt Exp $ +# $OpenBSD: Makefile,v 1.3 2003/06/01 17:00:39 deraadt Exp $ LIB= kern @@ -16,8 +16,8 @@ AFLAGS= -x assembler-with-cpp -traditional-cpp -I${.CURDIR}/../include \ -I${.CURDIR}/../../../../lib/libkern/arch/sparc # kern routines -SRCS= __main.c ashrdi3.c bzero.S divdi3.c qdivrem.c strlen.S strcat.c \ - strcmp.c strcpy.c strncmp.c umoddi3.c +SRCS= __main.c ashrdi3.c bzero.S divdi3.c qdivrem.c strlen.S \ + strcmp.c strncmp.c umoddi3.c SRCS+= umul.S mul.S rem.S sdiv.S udiv.S urem.S SRCS+= saveregs.S diff --git a/sys/arch/sparc/stand/libsa/Makefile b/sys/arch/sparc/stand/libsa/Makefile index 68e3495cf31..0002c987e1a 100644 --- a/sys/arch/sparc/stand/libsa/Makefile +++ b/sys/arch/sparc/stand/libsa/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.1 1997/09/17 10:46:23 downsj Exp $ +# $OpenBSD: Makefile,v 1.2 2003/06/01 17:00:39 deraadt Exp $ LIB= sa @@ -11,7 +11,7 @@ CFLAGS= -O2 -D__INTERNAL_LIBSA_CREAD \ # stand routines SRCS= alloc.c exit.c exec.c getfile.c gets.c globals.c \ - memcmp.c memcpy.c memset.c printf.c strerror.c strncpy.c + memcmp.c memcpy.c memset.c printf.c snprintf.c strerror.c strncpy.c # io routines SRCS+= close.c closeall.c dev.c disklabel.c dkcksum.c fstat.c ioctl.c lseek.c \ |