-rw-r--r-- | lib/util.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/util.cc b/lib/util.cc index 94f6f53..94e09ed 100644 --- a/lib/util.cc +++ b/lib/util.cc | |||
@@ -30,5 +30,6 @@ namespace opkele { | |||
30 | BIO_push(b64,bmem); | 30 | BIO_push(b64,bmem); |
31 | if(BIO_write(b64,data,length)!=length) | 31 | if(((size_t)BIO_write(b64,data,length))!=length) |
32 | throw exception_openssl(OPKELE_CP_ "failed to BIO_write()"); | 32 | throw exception_openssl(OPKELE_CP_ "failed to BIO_write()"); |
33 | BIO_flush(b64); | 33 | if(BIO_flush(b64)!=1) |
34 | throw exception_openssl(OPKELE_CP_ "failed to BIO_flush()"); | ||
34 | char *rvd; | 35 | char *rvd; |
@@ -146,3 +147,3 @@ namespace opkele { | |||
146 | int r=snprintf(rv,sizeof(rv),"%ld",l); | 147 | int r=snprintf(rv,sizeof(rv),"%ld",l); |
147 | if(r<0 || r>=sizeof(rv)) | 148 | if(r<0 || r>=(int)sizeof(rv)) |
148 | throw failed_conversion(OPKELE_CP_ "failed to snprintf()"); | 149 | throw failed_conversion(OPKELE_CP_ "failed to snprintf()"); |