diff options
author | Richard Levitte <levitte@openssl.org> | 2003-09-09 18:48:52 +0400 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2003-09-09 18:48:52 +0400 |
commit | 245dac4d175ef7ac132887bcdcf331f4822d3d58 (patch) | |
tree | a368cd89b7d3ed249e448612a4c234c01beedaf0 /e_os.h | |
parent | c377882c390cb327a000c03f5a3b6f8f34be4988 (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.h | 21 |
1 files changed, 20 insertions, 1 deletions
@@ -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 */ |