summaryrefslogtreecommitdiff
path: root/encoding.js
diff options
context:
space:
mode:
authorerdgeist <>2008-06-13 23:22:33 +0000
committererdgeist <>2008-06-13 23:22:33 +0000
commit4c122001aff4c2f03491ab4cc736cfdf7a32272c (patch)
tree5603c7fcdfb90c4db8fde0a1ce962376f03b7ce7 /encoding.js
parent83258625a9f176cfabf39f63d3d4deeec3212c73 (diff)
Fixed decode_quotedprintableHEADmaster
Diffstat (limited to 'encoding.js')
-rw-r--r--encoding.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/encoding.js b/encoding.js
index 1370eb7..a0864ea 100644
--- a/encoding.js
+++ b/encoding.js
@@ -35,10 +35,10 @@ function decode_quotedprintable( str ) {
35 var lines = str.replace( /_/g, " ").split( "=" ); 35 var lines = str.replace( /_/g, " ").split( "=" );
36 var outstring = [ lines[0] ]; 36 var outstring = [ lines[0] ];
37 for( var i=1; i< lines.length; ++i ) { 37 for( var i=1; i< lines.length; ++i ) {
38 if( lines[i].charCodeAt(1) == 10 ) { 38 if( lines[i].charCodeAt(0) == 10 ) {
39 outstring.push( lines[i].substring( 2 ) ); 39 outstring.push( lines[i].substring( 1 ) );
40 } else { 40 } else {
41 outstring.push( String.fromCharCode( parseInt( lines[i].substring(0,2), 16 ) ), lines[i].substring( 2 ) ) 41 outstring.push( String.fromCharCode( parseInt( lines[i].substring(0,2), 16 ) ), lines[i].substring( 2 ) );
42 } 42 }
43 } 43 }
44 return outstring.join( '' ); 44 return outstring.join( '' );