home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 9 / FreshFishVol9-CD2.bin / bbs / gnu / libnix-0.8-src.lha / libnix-0.8 / sources / nix / string / strcoll.c < prev    next >
Encoding:
C/C++ Source or Header  |  1994-12-12  |  365 b   |  16 lines

  1. #include <locale.h>
  2. #include <libraries/locale.h>
  3. #ifdef __GNUC__
  4. #include <inline/locale.h>
  5. #endif
  6. #include <limits.h>
  7.  
  8. extern struct Locale *__localevec[];
  9.  
  10. int strcoll(const char *s1,const char *s2)
  11. { if(__localevec[LC_COLLATE-1]==NULL)
  12.     return strcmp(s1,s2);
  13.   else
  14.     return StrnCmp(__localevec[LC_COLLATE-1],(char *)s1,(char *)s2,LONG_MAX,SC_COLLATE1);
  15. }
  16.