1
0
mirror of https://github.com/moparisthebest/curl synced 2024-12-21 23:58:49 -05:00

on albert chin's comment I remade the fix to set '\0' instead of 0 since

they're chars
This commit is contained in:
Daniel Stenberg 2001-04-24 06:12:07 +00:00
parent be49b01952
commit 0b7e0638a9

View File

@ -41,12 +41,12 @@ char *curl_version(void)
#if (SSLEAY_VERSION_NUMBER >= 0x906000) #if (SSLEAY_VERSION_NUMBER >= 0x906000)
{ {
char sub[2]; char sub[2];
sub[1]=0; sub[1]='\0';
if(SSLEAY_VERSION_NUMBER&0xff0) { if(SSLEAY_VERSION_NUMBER&0xff0) {
sub[0]=((SSLEAY_VERSION_NUMBER>>4)&0xff) + 'a' -1; sub[0]=((SSLEAY_VERSION_NUMBER>>4)&0xff) + 'a' -1;
} }
else else
sub[0]=0; sub[0]='\0';
sprintf(ptr, " (OpenSSL %lx.%lx.%lx%s)", sprintf(ptr, " (OpenSSL %lx.%lx.%lx%s)",
(SSLEAY_VERSION_NUMBER>>28)&0xf, (SSLEAY_VERSION_NUMBER>>28)&0xf,
@ -64,12 +64,12 @@ char *curl_version(void)
#else #else
{ {
char sub[2]; char sub[2];
sub[1]=0; sub[1]='\0';
if(SSLEAY_VERSION_NUMBER&0x0f) { if(SSLEAY_VERSION_NUMBER&0x0f) {
sub[0]=(SSLEAY_VERSION_NUMBER&0x0f) + 'a' -1; sub[0]=(SSLEAY_VERSION_NUMBER&0x0f) + 'a' -1;
} }
else else
sub[0]=0; sub[0]='\0';
sprintf(ptr, " (SSL %x.%x.%x%s)", sprintf(ptr, " (SSL %x.%x.%x%s)",
(SSLEAY_VERSION_NUMBER>>12)&0xff, (SSLEAY_VERSION_NUMBER>>12)&0xff,