From: Ulrich Drepper Date: Fri, 13 Mar 1998 17:41:43 +0000 (+0000) Subject: Correct handling of separators after last non-separator. X-Git-Tag: cvs/before-sparc-2_0_x-branch~72 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7d81981b6c1a6c5bd14fcc108c7a765cb2111c1b;p=thirdparty%2Fglibc.git Correct handling of separators after last non-separator. --- diff --git a/sysdeps/generic/strsep.c b/sysdeps/generic/strsep.c index 15c5891044d..22a27528ef1 100644 --- a/sysdeps/generic/strsep.c +++ b/sysdeps/generic/strsep.c @@ -1,4 +1,4 @@ -/* Copyright (C) 1992, 1993, 1996 Free Software Foundation, Inc. +/* Copyright (C) 1992, 1993, 1996, 1998 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -24,7 +24,7 @@ __strsep (char **stringp, const char *delim) char *begin, *end; begin = *stringp; - if (! begin || *begin == '\0') + if (begin == NULL) return NULL; /* Find the end of the token. */