Эх сурвалжийг харах

Windows Zeilenumbrüche aus antwort entfernt

Kolja Strohm 6 жил өмнө
parent
commit
e1307bde2c

+ 4 - 0
Network/HttpRequest.cpp

@@ -65,6 +65,8 @@ Answer::Answer( const char *answer )
     TextReader reader( new Text( answer ) );
     // parse header
     Text *line = reader.leseZeile();
+    line->remove( "\r\n" );
+    line->remove( "\n" );
     header += *line;
     header += "\n";
     int trenn = line->positionVon( " " );
@@ -82,6 +84,8 @@ Answer::Answer( const char *answer )
     while( !reader.istEnde() )
     {
         Text *line = reader.leseZeile();
+        line->remove( "\r\n" );
+        line->remove( "\n" );
         if( line->getLength() > 0 )
         {
             header += *line;