patch to src/event/ngx_event_openssl.c (nginx 1.6.2)

173279834462 nginx-forum at nginx.us
Sun Feb 1 16:05:49 UTC 2015


nginx-1.6.2

>make

[...]
src/event/ngx_event_openssl.c:2520:9: error: implicit declaration of
function 'RAND_pseudo_bytes' is invalid in C99
[-Werror,-Wimplicit-function-declaration]
        RAND_pseudo_bytes(iv, 16);
        ^
1 error generated.


patch:

perl -i.bak -0p -e 's|(^#include <ngx_event.h>).*(typedef
struct)|$1\n#include <openssl\/rand\.h>\n\nint RAND_bytes\(unsigned char
\*buf, int num\);\nint RAND_pseudo_bytes\(unsigned char \*buf, int
num\);\n\n$2|ms' ./src/event/ngx_event_openssl.c;

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,256382,256382#msg-256382



More information about the nginx mailing list