projects
/
oweals
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Change BIO_number_read and BIO_number_written() to be 64 bit
[oweals/openssl.git]
/
demos
/
b64.c
diff --git
a/demos/b64.c
b/demos/b64.c
index fcc69562c134afa33fa109d95d45ffa8c101b4c6..c01107f4a0bebf50becc4ef0ae0efe1bf6358eee 100644
(file)
--- a/
demos/b64.c
+++ b/
demos/b64.c
@@
-169,7
+169,7
@@
char **argv;
}
strbuf = OPENSSL_malloc(SIZE);
}
strbuf = OPENSSL_malloc(SIZE);
- buff =
(unsigned char *)
OPENSSL_malloc(EVP_ENCODE_LENGTH(bsize));
+ buff = OPENSSL_malloc(EVP_ENCODE_LENGTH(bsize));
if ((buff == NULL) || (strbuf == NULL)) {
BIO_printf(bio_err, "OPENSSL_malloc failure\n");
goto end;
if ((buff == NULL) || (strbuf == NULL)) {
BIO_printf(bio_err, "OPENSSL_malloc failure\n");
goto end;
@@
-239,10
+239,8
@@
char **argv;
BIO_printf(bio_err, "bytes written:%8ld\n", BIO_number_written(out));
}
end:
BIO_printf(bio_err, "bytes written:%8ld\n", BIO_number_written(out));
}
end:
- if (strbuf != NULL)
- OPENSSL_free(strbuf);
- if (buff != NULL)
- OPENSSL_free(buff);
+ OPENSSL_free(strbuf);
+ OPENSSL_free(buff);
BIO_free(in);
BIO_free(out);
BIO_free(benc);
BIO_free(in);
BIO_free(out);
BIO_free(benc);