diff options
author | markus <> | 2003-05-12 02:18:40 +0000 |
---|---|---|
committer | markus <> | 2003-05-12 02:18:40 +0000 |
commit | d4fcd82bb7f6d603bd61e19a81ba97337b89dfca (patch) | |
tree | d52e3a0f1f08f65ad283027e560e17ed0d720462 /src/lib/libcrypto/rand/rand_egd.c | |
parent | 582bbd139cd2afd58d10dc051c5b0b989b441074 (diff) | |
download | openbsd-d4fcd82bb7f6d603bd61e19a81ba97337b89dfca.tar.gz openbsd-d4fcd82bb7f6d603bd61e19a81ba97337b89dfca.tar.bz2 openbsd-d4fcd82bb7f6d603bd61e19a81ba97337b89dfca.zip |
merge 0.9.7b with local changes; crank majors for libssl/libcrypto
Diffstat (limited to 'src/lib/libcrypto/rand/rand_egd.c')
-rw-r--r-- | src/lib/libcrypto/rand/rand_egd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libcrypto/rand/rand_egd.c b/src/lib/libcrypto/rand/rand_egd.c index 96019c07a6..895967476e 100644 --- a/src/lib/libcrypto/rand/rand_egd.c +++ b/src/lib/libcrypto/rand/rand_egd.c | |||
@@ -94,7 +94,7 @@ | |||
94 | * RAND_egd() is a wrapper for RAND_egd_bytes() with numbytes=255. | 94 | * RAND_egd() is a wrapper for RAND_egd_bytes() with numbytes=255. |
95 | */ | 95 | */ |
96 | 96 | ||
97 | #if defined(OPENSSL_SYS_WIN32) || defined(OPENSSL_SYS_VMS) || defined(__DJGPP__) | 97 | #if defined(OPENSSL_SYS_WIN32) || defined(OPENSSL_SYS_VMS) || defined(OPENSSL_SYS_MSDOS) || defined(OPENSSL_SYS_VXWORKS) |
98 | int RAND_query_egd_bytes(const char *path, unsigned char *buf, int bytes) | 98 | int RAND_query_egd_bytes(const char *path, unsigned char *buf, int bytes) |
99 | { | 99 | { |
100 | return(-1); | 100 | return(-1); |
@@ -114,7 +114,7 @@ int RAND_egd_bytes(const char *path,int bytes) | |||
114 | #include <sys/types.h> | 114 | #include <sys/types.h> |
115 | #include <sys/socket.h> | 115 | #include <sys/socket.h> |
116 | #ifndef NO_SYS_UN_H | 116 | #ifndef NO_SYS_UN_H |
117 | # ifdef OPENSSL_SYS_VSWORKS | 117 | # ifdef OPENSSL_SYS_VXWORKS |
118 | # include <streams/un.h> | 118 | # include <streams/un.h> |
119 | # else | 119 | # else |
120 | # include <sys/un.h> | 120 | # include <sys/un.h> |
@@ -143,7 +143,7 @@ int RAND_query_egd_bytes(const char *path, unsigned char *buf, int bytes) | |||
143 | 143 | ||
144 | memset(&addr, 0, sizeof(addr)); | 144 | memset(&addr, 0, sizeof(addr)); |
145 | addr.sun_family = AF_UNIX; | 145 | addr.sun_family = AF_UNIX; |
146 | if (strlen(path) > sizeof(addr.sun_path)) | 146 | if (strlen(path) >= sizeof(addr.sun_path)) |
147 | return (-1); | 147 | return (-1); |
148 | strlcpy(addr.sun_path,path,sizeof addr.sun_path); | 148 | strlcpy(addr.sun_path,path,sizeof addr.sun_path); |
149 | len = offsetof(struct sockaddr_un, sun_path) + strlen(path); | 149 | len = offsetof(struct sockaddr_un, sun_path) + strlen(path); |