X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fupdate.cc;h=c50022091fbe3ab6abb0169e86fa00e7444c4cb3;hb=c2ad65492410eb40de5fea037a39c7a1a0693a43;hp=44ecbb232c26b03214f23d3191c54fedd9a9071a;hpb=cc27c2716f755305d67f1e1ba828ecf37f8405dd;p=dcpomatic.git diff --git a/src/lib/update.cc b/src/lib/update.cc index 44ecbb232..c50022091 100644 --- a/src/lib/update.cc +++ b/src/lib/update.cc @@ -18,7 +18,6 @@ */ #include -#include #include #include #include @@ -26,13 +25,13 @@ #include "update.h" #include "version.h" #include "ui_signaller.h" +#include "safe_stringstream.h" #define BUFFER_SIZE 1024 using std::cout; using std::min; using std::string; -using std::stringstream; using dcp::raw_convert; /** Singleton instance */ @@ -113,10 +112,9 @@ UpdateChecker::thread () /* Parse the reply */ _buffer[_offset] = '\0'; - stringstream s; - s << _buffer; + string s (_buffer); cxml::Document doc ("Update"); - doc.read_stream (s); + doc.read_string (s); { boost::mutex::scoped_lock lm (_data_mutex);