Skip Menu |
 

This queue is for tickets about the Net-SSLeay CPAN distribution.

Report information
The Basics
Id: 71406
Status: resolved
Worked: 15 min
Priority: 0/
Queue: Net-SSLeay

People
Owner: MIKEM [...] cpan.org
Requestors: asavige [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in:
  • 1.37
  • 1.38
  • 1.39
  • 1.40
  • 1.41
Fixed in: (no value)



Subject: SSLeay.xs line 1766 assumes ANSI C99 compiler
Download (untitled) / with headers
text/plain 1017b
When building Net-SSLeay-1.41, I got a compile error with Net-SSLeay.c when building on Windows with MSVC6 with a very odd compiler error message: SSLeay.xs(1766) : error C2275: 'FILE' : illegal use of this type as an expression Digging further, I noticed that the change to SSLeay.xs introduced in Net-SSLeay-1.37 is assuming ANSI C99 in function CTX_use_PKCS12_file() in that in: CODE: RETVAL = 1; FILE *fp = fopen (file, "r"); The declaration of fp occurs after "RETVAL = 1". The following simple re-ordering fixed my compilation problem: --- SSLeay-orig.xs 2011-09-25 07:09:07.000000000 +1000 +++ SSLeay.xs 2011-10-03 15:51:07.000000000 +1100 @@ -1760,10 +1760,11 @@ EVP_PKEY* private_key; X509* certificate; SSL_CTX * ctx1; + FILE *fp; CODE: RETVAL = 1; - FILE *fp = fopen (file, "r"); + fp = fopen (file, "r"); bio = BIO_new(BIO_s_mem()); while(count = fread(buffer, 1, sizeof(buffer), fp)) BIO_write(bio, buffer, count);
Download (untitled) / with headers
text/plain 100b
Thanks for reporting and patching this. It has now been fixed in new release version 1.42. Cheers.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.