Borland C++ 5.5 warns about:
.\crypto\rand\randfile.c:
Warning W8017 d:\prg\Bcc55\include\sys/stat.h 34: Redefinition of 
'S_IFMT' is not identical
Warning W8017 d:\prg\Bcc55\include\sys/stat.h 35: Redefinition of 
'S_IFDIR' is not identical

and:
.\crypto\x509\by_dir.c:
Warning W8017 d:\prg\Bcc55\include\sys/stat.h 34: Redefinition of 
'S_IFMT' is not identical
Warning W8017 d:\prg\Bcc55\include\sys/stat.h 35: Redefinition of 
'S_IFDIR' is not identical

in e_os.h we have:
#  ifndef S_IFDIR
#    define S_IFDIR     _S_IFDIR
#  endif

#  ifndef S_IFMT
#    define S_IFMT      _S_IFMT
#  endif

now the prob is that randfile.c as well as by_dir.c both include e_os.h 
(by_dir.c via cryptlib.h) *before* including sys/stat.h - therefore the 
test in e_os.h for these defines is useless. One option would be to 
include sys/stat.h in e_os.h before testing these defines, but I've no 
idea if all platforms which process this block really have a sys/stat.h 
(maybe _WIN32_WCE has not?);
else the warnings are cured with surrounding these defines with '#ifndef 
__BORLANDC__':
--- e_os.h.org  Tue Jan 11 15:08:35 2011
+++ e_os.h      Tue Jan 11 15:37:55 2011
@@ -236,12 +236,14 @@
  #    define DEVRANDOM "/dev/urandom\x24"
  #  endif /* __DJGPP__ */

-#  ifndef S_IFDIR
-#    define S_IFDIR    _S_IFDIR
-#  endif
+#  if !defined (__BORLANDC__)
+#    ifndef S_IFDIR
+#      define S_IFDIR  _S_IFDIR
+#    endif

-#  ifndef S_IFMT
-#    define S_IFMT     _S_IFMT
+#    ifndef S_IFMT
+#      define S_IFMT   _S_IFMT
+#    endif
  #  endif

  #  if !defined(WINNT) && !defined(__DJGPP__)

This prob exists with OpenSSL 0.9.8q as well as with 1.0.0c.


______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
Development Mailing List                       [email protected]
Automated List Manager                           [email protected]

Reply via email to