Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/openssl/openssl.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/e_os.h
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2003-09-09 18:48:52 +0400
committerRichard Levitte <levitte@openssl.org>2003-09-09 18:48:52 +0400
commit245dac4d175ef7ac132887bcdcf331f4822d3d58 (patch)
treea368cd89b7d3ed249e448612a4c234c01beedaf0 /e_os.h
parentc377882c390cb327a000c03f5a3b6f8f34be4988 (diff)
Generalise the definition of strcasecmp() and strncasecmp() for
platforms that don't (necessarely) have it. In the case of VMS, this means moving a couple of functions from apps/ to crypto/ and make them general (although only used privately).
Diffstat (limited to 'e_os.h')
-rw-r--r--e_os.h21
1 files changed, 20 insertions, 1 deletions
diff --git a/e_os.h b/e_os.h
index 4c6e70dffa..16126b2a38 100644
--- a/e_os.h
+++ b/e_os.h
@@ -503,11 +503,30 @@ extern char *sys_errlist[]; extern int sys_nerr;
#define IRIX_CC_BUG /* CDS++ up to V2.0Bsomething suffered from the same bug.*/
#endif
+#if defined(OPENSSL_SYS_WINDOWS)
+# define strcasecmp _stricmp
+# define strncasecmp _strnicmp
+#elif defined(OPENSSL_SYS_VMS)
+/* VMS below version 7.0 doesn't have strcasecmp() */
+# include <openssl/o_str.h>
+# define strcasecmp OPENSSL_strcasecmp
+# define strncasecmp OPENSSL_strncasecmp
+#elif defined(OPENSSL_SYS_OS2) && defined(__EMX__)
+# define strcasecmp stricmp
+# define strncasecmp strnicmp
+#else
+# ifdef NO_STRINGS_H
+ int strcasecmp();
+ int strncasecmp();
+# else
+# include <strings.h>
+# endif /* NO_STRINGS_H */
+#endif
+
#if defined(OPENSSL_SYS_OS2) && defined(__EMX__)
# include <io.h>
# include <fcntl.h>
# define NO_SYSLOG
-# define strcasecmp stricmp
#endif
/* vxworks */