提交 9d9dc6ac 编写于 作者: A Andy Polyakov

o_fopen.c,rand/randfile.c: compensate for e_os.h omission.

At earlier point e_os.h was omitted from a number of headers (in order
to emphasize OS neutrality), but this affected o_fopen.c and randfile.c
which are not OS-neutral, and contain some Win32-specific code.
Reviewed-by: NRich Salz <rsalz@openssl.org>
Reviewed-by: NRichard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/5676)
上级 4af14b7b
......@@ -12,6 +12,9 @@
#if !defined(OPENSSL_NO_STDIO)
# include <stdio.h>
# ifdef _WIN32
# include <windows.h>
# endif
FILE *openssl_fopen(const char *filename, const char *mode)
{
......
......@@ -26,7 +26,12 @@
# include <sys/stat.h>
# include <fcntl.h>
# ifdef _WIN32
# include <windows.h>
# include <io.h>
# define stat _stat
# define chmod _chmod
# define open _open
# define fdopen _fdopen
# endif
#endif
......@@ -41,13 +46,6 @@
# define S_ISREG(m) ((m) & S_IFREG)
# endif
#ifdef _WIN32
# define stat _stat
# define chmod _chmod
# define open _open
# define fdopen _fdopen
#endif
#define RAND_FILE_SIZE 1024
#define RFILE ".rnd"
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册