diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-05-10 21:11:15 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2003-05-10 21:11:15 +0000 |
commit | 607ced2a9825cfbbaa96cea1eeeb0ffa4c3a73a9 (patch) | |
tree | a0748894e4753ac59df5b3f28ac342b4b8e01e95 /sys/arch/hp300/dev | |
parent | 3feefc3c4b3f125fc274b71cfe392f9151b9a489 (diff) |
string cleaning; ok beck dhartmei
Diffstat (limited to 'sys/arch/hp300/dev')
-rw-r--r-- | sys/arch/hp300/dev/dio.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/arch/hp300/dev/dio.c b/sys/arch/hp300/dev/dio.c index eb4ecaf449b..551ca5e63ff 100644 --- a/sys/arch/hp300/dev/dio.c +++ b/sys/arch/hp300/dev/dio.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dio.c,v 1.7 2002/03/14 01:26:30 millert Exp $ */ +/* $OpenBSD: dio.c,v 1.8 2003/05/10 21:11:12 deraadt Exp $ */ /* $NetBSD: dio.c,v 1.7 1997/05/05 21:00:32 thorpej Exp $ */ /*- @@ -283,7 +283,7 @@ dio_devinfo(da, buf, buflen) * consistent/reliable device ids. */ if (da->da_scode == 7 && internalhpib) { - sprintf(buf, DIO_DEVICE_DESC_IHPIB); + snprintf(buf, buflen, DIO_DEVICE_DESC_IHPIB); return (buf); } @@ -300,7 +300,8 @@ dio_devinfo(da, buf, buflen) } } else { foundit: - sprintf(buf, "%s", dio_devdescs[i].dd_desc); + snprintf(buf, buflen, "%s", + dio_devdescs[i].dd_desc); return (buf); } } @@ -310,7 +311,7 @@ dio_devinfo(da, buf, buflen) /* * Device is unknown. Construct something reasonable. */ - sprintf(buf, "device id = 0x%x secid = 0x%x", + snprintf(buf, buflen, "device id = 0x%x secid = 0x%x", da->da_id, da->da_secid); return (buf); } |