home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 206.lha / C-Functions / strlencmp.c < prev    next >
C/C++ Source or Header  |  1996-02-14  |  283b  |  13 lines

  1.  
  2. #include <exec/types.h>
  3.  
  4. int strlencmp (s,t,n)   /* Stringcompare n letters; NULL if s == t */
  5. UBYTE s[], t[];         /* End at first '\0' ( if found ) */
  6. int n;
  7.    {
  8. register int i=0;
  9.    while ( (i<n-1) && s[i] == t[i] && s[i] && t[i]) i++;
  10.    return( (int)(s[i] - t[i]) );
  11.    }
  12.  
  13.