You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by pe...@apache.org on 2002/02/11 22:28:24 UTC
cvs commit: xml-xerces/c/src/xercesc/util Base64.hpp
peiyongz 02/02/11 13:28:24
Modified: c/src/xercesc/util Base64.hpp
Log:
Fix to Bug# 6330
Revision Changes Path
1.2 +4 -4 xml-xerces/c/src/xercesc/util/Base64.hpp
Index: Base64.hpp
===================================================================
RCS file: /home/cvs/xml-xerces/c/src/xercesc/util/Base64.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- Base64.hpp 1 Feb 2002 22:22:09 -0000 1.1
+++ Base64.hpp 11 Feb 2002 21:28:24 -0000 1.2
@@ -55,7 +55,7 @@
*/
/*
- * $Id: Base64.hpp,v 1.1 2002/02/01 22:22:09 peiyongz Exp $
+ * $Id: Base64.hpp,v 1.2 2002/02/11 21:28:24 peiyongz Exp $
*/
#ifndef BASE64_HPP
@@ -201,17 +201,17 @@
}
inline void Base64::split1stOctet(const XMLCh& ch, XMLCh& b1, XMLCh& b2) {
- b1 = ch >> 2;
+ b1 = ( ch & 0xff ) >> 2;
b2 = ( ch & 0x3 ) << 4;
}
inline void Base64::split2ndOctet(const XMLCh& ch, XMLCh& b2, XMLCh& b3) {
- b2 |= ch >> 4; // combine with previous value
+ b2 |= ( ch & 0xff ) >> 4; // combine with previous value
b3 = ( ch & 0xf ) << 2;
}
inline void Base64::split3rdOctet(const XMLCh& ch, XMLCh& b3, XMLCh& b4) {
- b3 |= ch >> 6; // combine with previous value
+ b3 |= ( ch & 0xff) >> 6; // combine with previous value
b4 = ( ch & 0x3f );
}
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-cvs-help@xml.apache.org