mirror of
https://github.com/SFML/SFML.git
synced 2024-12-01 15:51:04 +08:00
Fixed extra empty line at end of Http::Response body
git-svn-id: https://sfml.svn.sourceforge.net/svnroot/sfml/trunk@1431 4e206d99-4929-0410-ac5d-dfc041789085
This commit is contained in:
parent
0d0889fc2b
commit
4a840d4f48
@ -27,6 +27,8 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Network/Http.hpp>
|
||||
#include <ctype.h>
|
||||
#include <algorithm>
|
||||
#include <iterator>
|
||||
#include <sstream>
|
||||
|
||||
|
||||
@ -295,8 +297,7 @@ void Http::Response::FromString(const std::string& Data)
|
||||
|
||||
// Finally extract the body
|
||||
myBody.clear();
|
||||
while (std::getline(In, Line))
|
||||
myBody += Line + "\n";
|
||||
std::copy(std::istreambuf_iterator<char>(In), std::istreambuf_iterator<char>(), std::back_inserter(myBody));
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user