diff options
author | bde <bde@FreeBSD.org> | 1996-08-31 16:52:44 +0000 |
---|---|---|
committer | bde <bde@FreeBSD.org> | 1996-08-31 16:52:44 +0000 |
commit | 070eb30ca675029e79f93333b60287527efc0906 (patch) | |
tree | d0ca99d3f53a0fe4ea60e83d05baa8825fdd8cc4 /sys/libkern/strcmp.c | |
parent | db0af2c4dc8e05c93d178bf31653024d244398bb (diff) | |
download | FreeBSD-src-070eb30ca675029e79f93333b60287527efc0906.zip FreeBSD-src-070eb30ca675029e79f93333b60287527efc0906.tar.gz |
Fixed the easy cases of const poisoning in the kernel. Cosmetic.
Diffstat (limited to 'sys/libkern/strcmp.c')
-rw-r--r-- | sys/libkern/strcmp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/libkern/strcmp.c b/sys/libkern/strcmp.c index c9c397b..48e5635 100644 --- a/sys/libkern/strcmp.c +++ b/sys/libkern/strcmp.c @@ -33,7 +33,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id$ + * $Id: strcmp.c,v 1.2 1994/08/02 07:44:33 davidg Exp $ */ #include <sys/cdefs.h> @@ -49,5 +49,5 @@ strcmp(s1, s2) while (*s1 == *s2++) if (*s1++ == 0) return (0); - return (*(unsigned char *)s1 - *(unsigned char *)--s2); + return (*(const unsigned char *)s1 - *(const unsigned char *)(s2 - 1)); } |