Juan Lang : crypt32: Fix overestimating size required for base64-encoded strings.

Alexandre Julliard julliard at winehq.org
Mon Mar 22 11:11:59 CDT 2010


Module: wine
Branch: master
Commit: 67bf4dc62e7a9e459cfe16f0cc34cbe3a93e919f
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=67bf4dc62e7a9e459cfe16f0cc34cbe3a93e919f

Author: Juan Lang <juan.lang at gmail.com>
Date:   Fri Mar 19 15:51:24 2010 -0700

crypt32: Fix overestimating size required for base64-encoded strings.

---

 dlls/crypt32/base64.c |    4 ----
 1 files changed, 0 insertions(+), 4 deletions(-)

diff --git a/dlls/crypt32/base64.c b/dlls/crypt32/base64.c
index 4a6504a..2a91372 100644
--- a/dlls/crypt32/base64.c
+++ b/dlls/crypt32/base64.c
@@ -204,8 +204,6 @@ static BOOL BinaryToBase64A(const BYTE *pbBinary,
 
     charsNeeded = 0;
     encodeBase64A(pbBinary, cbBinary, sep, NULL, &charsNeeded);
-    if (sep)
-        charsNeeded += strlen(sep);
     if (header)
         charsNeeded += strlen(header) + strlen(sep);
     if (trailer)
@@ -409,8 +407,6 @@ static BOOL BinaryToBase64W(const BYTE *pbBinary,
 
     charsNeeded = 0;
     encodeBase64W(pbBinary, cbBinary, sep, NULL, &charsNeeded);
-    if (sep)
-        charsNeeded += strlenW(sep);
     if (header)
         charsNeeded += strlenW(header) + strlenW(sep);
     if (trailer)




More information about the wine-cvs mailing list