push more things in the str lib.
[apps/madmutt.git] / base64.c
index df55689..728171b 100644 (file)
--- a/base64.c
+++ b/base64.c
@@ -51,10 +51,10 @@ void mutt_to_base64 (unsigned char *out, const unsigned char *in, size_t len,
                      size_t olen)
 {
   while (len >= 3 && olen > 10) {
-    *out++ = B64Chars[in[0] >> 2];
-    *out++ = B64Chars[((in[0] << 4) & 0x30) | (in[1] >> 4)];
-    *out++ = B64Chars[((in[1] << 2) & 0x3c) | (in[2] >> 6)];
-    *out++ = B64Chars[in[2] & 0x3f];
+    *out++ = __m_b64chars[in[0] >> 2];
+    *out++ = __m_b64chars[((in[0] << 4) & 0x30) | (in[1] >> 4)];
+    *out++ = __m_b64chars[((in[1] << 2) & 0x3c) | (in[2] >> 6)];
+    *out++ = __m_b64chars[in[2] & 0x3f];
     olen -= 4;
     len -= 3;
     in += 3;
@@ -64,12 +64,12 @@ void mutt_to_base64 (unsigned char *out, const unsigned char *in, size_t len,
   if (len > 0 && olen > 4) {
     unsigned char fragment;
 
-    *out++ = B64Chars[in[0] >> 2];
+    *out++ = __m_b64chars[in[0] >> 2];
     fragment = (in[0] << 4) & 0x30;
     if (len > 1)
       fragment |= in[1] >> 4;
-    *out++ = B64Chars[fragment];
-    *out++ = (len < 2) ? '=' : B64Chars[(in[1] << 2) & 0x3c];
+    *out++ = __m_b64chars[fragment];
+    *out++ = (len < 2) ? '=' : __m_b64chars[(in[1] << 2) & 0x3c];
     *out++ = '=';
   }
   *out = '\0';