diff options
author | nobody <nobody@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2005-05-05 12:53:55 +0000 |
---|---|---|
committer | nobody <nobody@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2005-05-05 12:53:55 +0000 |
commit | 3c61e20f081bf6fbab6d3483e5e7f71cb91c4974 (patch) | |
tree | 4d687030d8e848eb2c325e8234fb807f578df890 /ace/OS_NS_strings.cpp | |
parent | 65ce81267a19f490a22443567c75276fc864cbd2 (diff) | |
download | ATCD-RepositoryManager.tar.gz |
This commit was manufactured by cvs2svn to create branchRepositoryManager
'RepositoryManager'.
Diffstat (limited to 'ace/OS_NS_strings.cpp')
-rw-r--r-- | ace/OS_NS_strings.cpp | 81 |
1 files changed, 0 insertions, 81 deletions
diff --git a/ace/OS_NS_strings.cpp b/ace/OS_NS_strings.cpp deleted file mode 100644 index 67ca3a809b8..00000000000 --- a/ace/OS_NS_strings.cpp +++ /dev/null @@ -1,81 +0,0 @@ -// -*- C++ -*- -// $Id$ - -#include "ace/OS_NS_strings.h" - -ACE_RCSID(ace, OS_NS_strings, "$Id$") - -#if !defined (ACE_HAS_INLINED_OSCALLS) -# include "ace/OS_NS_strings.inl" -#endif /* ACE_HAS_INLINED_OS_CALLS */ - -#if defined (ACE_LACKS_STRCASECMP) -# include "ace/OS_NS_ctype.h" -#endif /* ACE_LACKS_STRCASECMP */ - -#if defined (ACE_LACKS_STRCASECMP) -int -ACE_OS::strcasecmp_emulation (const char *s, const char *t) -{ - const char *scan1 = s; - const char *scan2 = t; - - while (*scan1 != 0 - && ACE_OS::ace_tolower (*scan1) - == ACE_OS::ace_tolower (*scan2)) - { - ++scan1; - ++scan2; - } - - // The following case analysis is necessary so that characters which - // look negative collate low against normal characters but high - // against the end-of-string NUL. - - if (*scan1 == '\0' && *scan2 == '\0') - return 0; - else if (*scan1 == '\0') - return -1; - else if (*scan2 == '\0') - return 1; - else - return ACE_OS::ace_tolower (*scan1) - ACE_OS::ace_tolower (*scan2); -} -#endif /* ACE_LACKS_STRCASECMP */ - -#if defined (ACE_LACKS_STRCASECMP) -int -ACE_OS::strncasecmp_emulation (const char *s, - const char *t, - size_t len) -{ - const char *scan1 = s; - const char *scan2 = t; - size_t count = 0; - - while (count++ < len - && *scan1 != 0 - && ACE_OS::ace_tolower (*scan1) - == ACE_OS::ace_tolower (*scan2)) - { - ++scan1; - ++scan2; - } - - if (count > len) - return 0; - - // The following case analysis is necessary so that characters which - // look negative collate low against normal characters but high - // against the end-of-string NUL. - - if (*scan1 == '\0' && *scan2 == '\0') - return 0; - else if (*scan1 == '\0') - return -1; - else if (*scan2 == '\0') - return 1; - else - return ACE_OS::ace_tolower (*scan1) - ACE_OS::ace_tolower (*scan2); -} -#endif /* ACE_LACKS_STRCASECMP */ |