Subversion Repositories Kolibri OS

Rev

Rev 647 | Go to most recent revision | Blame | Last modification | View Log | Download | RSS feed

  1. #include <string.h>
  2.  
  3. typedef unsigned char uc;
  4. int memcmp(const void* buf1,const void* buf2,size_t count)
  5. {
  6.         int i;
  7.         for (i=0;i<count;i++)
  8.         {
  9.                 if (*(uc*)buf1<*(uc*)buf2)
  10.                         return -1;
  11.                 if (*(uc*)buf1>*(uc*)buf2)
  12.                         return 1;
  13.         }
  14.         return 0;
  15. }
  16.