projects
/
oweals
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aebe039
)
Move an assert() to avoid core dumps when a static buffer hasn't been given.
author
Richard Levitte
<levitte@openssl.org>
Thu, 9 May 2002 18:19:45 +0000
(18:19 +0000)
committer
Richard Levitte
<levitte@openssl.org>
Thu, 9 May 2002 18:19:45 +0000
(18:19 +0000)
Notified by Verdon Walker <VWalker@novell.com>
crypto/bio/b_print.c
patch
|
blob
|
history
diff --git
a/crypto/bio/b_print.c
b/crypto/bio/b_print.c
index b7e268f092011b94bc2697ebc3ef9403c4401899..92f9f8f4e69995aa9facd17addfdd83edab1c1b5 100644
(file)
--- a/
crypto/bio/b_print.c
+++ b/
crypto/bio/b_print.c
@@
-716,12
+716,13
@@
doapr_outch(
if (buffer) {
while (*currlen >= *maxlen) {
if (*buffer == NULL) {
- assert(*sbuffer != NULL);
if (*maxlen == 0)
*maxlen = 1024;
*buffer = OPENSSL_malloc(*maxlen);
- if (*currlen > 0)
+ if (*currlen > 0) {
+ assert(*sbuffer != NULL);
memcpy(*buffer, *sbuffer, *currlen);
+ }
*sbuffer = NULL;
} else {
*maxlen += 1024;