X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Fstrchrnul.c;h=8d17f15909a8a92f7d3b1c073135bf5cc2fceb1e;hb=8de557e31178699dd6e839850056f0653cdfba89;hp=694e24a0ab3a2afd1ec316131a4dcb1750378cdd;hpb=2d0fc24aba5e2c71a55b991a6e0ba6a01110581f;p=gnulib.git diff --git a/lib/strchrnul.c b/lib/strchrnul.c index 694e24a0a..8d17f1590 100644 --- a/lib/strchrnul.c +++ b/lib/strchrnul.c @@ -13,19 +13,18 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, - Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ + Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ /* Specification. */ #include "strchrnul.h" /* Find the first occurrence of C in S or the final NUL byte. */ char * -strchrnul (s, c_in) - const char *s; - int c_in; +strchrnul (const char *s, int c_in) { - while (*s && (*s != c_in)) + char c = c_in; + while (*s && (*s != c)) s++; - return (char*) s; + return (char *) s; }