diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2006-01-17 20:22:39 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2006-01-17 20:22:39 +0000 |
commit | 786cf1313400d73786b44526d6df9eed3fc71829 (patch) | |
tree | 0d5a8ff14a3b74fab06fc169ec453c2457950843 /sys/scsi | |
parent | d71f94f8340b16fb4e5cb9ad2e7463776edd4a31 (diff) |
Use strchr() from libkern instead of rolling our own.
Diffstat (limited to 'sys/scsi')
-rw-r--r-- | sys/scsi/ss_scanjet.c | 21 |
1 files changed, 3 insertions, 18 deletions
diff --git a/sys/scsi/ss_scanjet.c b/sys/scsi/ss_scanjet.c index cc6e7dfc9b6..c0d5b606a35 100644 --- a/sys/scsi/ss_scanjet.c +++ b/sys/scsi/ss_scanjet.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ss_scanjet.c,v 1.27 2005/12/15 13:49:03 krw Exp $ */ +/* $OpenBSD: ss_scanjet.c,v 1.28 2006/01/17 20:22:38 miod Exp $ */ /* $NetBSD: ss_scanjet.c,v 1.6 1996/05/18 22:58:01 christos Exp $ */ /* @@ -66,9 +66,7 @@ int scanjet_set_window(struct ss_softc *, int); int scanjet_compute_sizes(struct ss_softc *, int); /* Maybe move to libkern? */ #define atoi local_atoi -#define strchr local_strchr __inline static int atoi(const char *); -__inline static char *strchr(/* const */ char *, char); /* @@ -453,8 +451,8 @@ scanjet_set_window(ss, flags) return (scanjet_ctl_write(ss, escape_codes, len, flags)); } -/* atoi() and strchr() are from /sys/arch/amiga/dev/ite.c - and are only used in scanjet_compute_sizes */ +/* atoi() is from /sys/arch/amiga/dev/ite.c + and is only used in scanjet_compute_sizes */ __inline static int atoi(cp) @@ -468,19 +466,6 @@ atoi(cp) return (n); } -__inline static char * -strchr(cp, ch) - /* - * The const was removed to make -Wcast-qual happy. I - * don't particularily like this solution but what to do? - */ - /* const */ char *cp; - char ch; -{ - while (*cp && *cp != ch) cp++; - return (*cp ? (char *)cp : 0); -} - int scanjet_compute_sizes(ss, flags) struct ss_softc *ss; |