aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authors_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b>2010-07-25 21:29:07 +0000
committers_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b>2010-07-25 21:29:07 +0000
commit7d46f9250cef06d248617085a7439e8ef8841cd7 (patch)
treed0b850d94f5ecd81d4841e86fc15f8bfae85f8b8
parent3b7cd5d89a226426df9c723d1f9ddfe08b7d1def (diff)
Lachesis: remove newlines every 64 characters in EncodeBase64
git-svn-id: https://bitcoin.svn.sourceforge.net/svnroot/bitcoin/trunk@110 1a98c847-1fd6-4fd8-948a-caf3550aa51b
-rw-r--r--rpc.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/rpc.cpp b/rpc.cpp
index cd69a3777c..bf522d0fa3 100644
--- a/rpc.cpp
+++ b/rpc.cpp
@@ -774,6 +774,10 @@ string EncodeBase64(string s)
string result(bptr->data, bptr->length-1);
BIO_free_all(b64);
+ // Remove newlines every 64 characters
+ result.erase(std::remove(result.begin(), result.end(), '\n'), result.end());
+ result.erase(std::remove(result.begin(), result.end(), '\r'), result.end());
+
return result;
}