aboutsummaryrefslogtreecommitdiffstats
path: root/src/utility/encoder
diff options
context:
space:
mode:
authorVincent Richard <[email protected]>2012-11-29 21:33:04 +0000
committerVincent Richard <[email protected]>2012-11-29 21:33:31 +0000
commit71f06fab915f20d10b4b97d6c927087228b51f6e (patch)
tree399177abb33447877be7e80c545c9f16ada1e078 /src/utility/encoder
parentBetter handling of SSL_ERROR_WANT_READ/SSL_ERROR_WANT_WRITE. Sockets on Windo... (diff)
downloadvmime-71f06fab915f20d10b4b97d6c927087228b51f6e.tar.gz
vmime-71f06fab915f20d10b4b97d6c927087228b51f6e.zip
Trivial 64-bit warning fixes.
Diffstat (limited to 'src/utility/encoder')
-rw-r--r--src/utility/encoder/b64Encoder.cpp4
-rw-r--r--src/utility/encoder/qpEncoder.cpp8
-rw-r--r--src/utility/encoder/uuEncoder.cpp8
3 files changed, 10 insertions, 10 deletions
diff --git a/src/utility/encoder/b64Encoder.cpp b/src/utility/encoder/b64Encoder.cpp
index 58ef3200..85c972f9 100644
--- a/src/utility/encoder/b64Encoder.cpp
+++ b/src/utility/encoder/b64Encoder.cpp
@@ -197,8 +197,8 @@ utility::stream::size_type b64Encoder::decode(utility::inputStream& in,
// Process the data
char buffer[16384];
- int bufferLength = 0;
- int bufferPos = 0;
+ utility::stream::size_type bufferLength = 0;
+ utility::stream::size_type bufferPos = 0;
utility::stream::size_type total = 0;
utility::stream::size_type inTotal = 0;
diff --git a/src/utility/encoder/qpEncoder.cpp b/src/utility/encoder/qpEncoder.cpp
index ab8db2e4..9e1c1ccd 100644
--- a/src/utility/encoder/qpEncoder.cpp
+++ b/src/utility/encoder/qpEncoder.cpp
@@ -178,8 +178,8 @@ utility::stream::size_type qpEncoder::encode(utility::inputStream& in,
// Process the data
char buffer[16384];
- int bufferLength = 0;
- int bufferPos = 0;
+ utility::stream::size_type bufferLength = 0;
+ utility::stream::size_type bufferPos = 0;
string::size_type curCol = 0;
@@ -380,8 +380,8 @@ utility::stream::size_type qpEncoder::decode(utility::inputStream& in,
const bool rfc2047 = getProperties().getProperty <bool>("rfc2047", false);
char buffer[16384];
- int bufferLength = 0;
- int bufferPos = 0;
+ utility::stream::size_type bufferLength = 0;
+ utility::stream::size_type bufferPos = 0;
unsigned char outBuffer[16384];
int outBufferPos = 0;
diff --git a/src/utility/encoder/uuEncoder.cpp b/src/utility/encoder/uuEncoder.cpp
index 0ddfbac6..4b4d83d8 100644
--- a/src/utility/encoder/uuEncoder.cpp
+++ b/src/utility/encoder/uuEncoder.cpp
@@ -52,15 +52,15 @@ const std::vector <string> uuEncoder::getAvailableProperties() const
// This is the character encoding function to make a character printable
-static inline unsigned char UUENCODE(const unsigned char c)
+static inline unsigned char UUENCODE(const unsigned long c)
{
- return ((c & 077) + ' ');
+ return static_cast <unsigned char>((c & 077) + ' ');
}
// Single character decoding
-static inline unsigned char UUDECODE(const unsigned char c)
+static inline unsigned char UUDECODE(const unsigned long c)
{
- return ((c - ' ') & 077);
+ return static_cast <unsigned char>((c - ' ') & 077);
}