Try to use platform independent input string stream
This commit is contained in:
parent
cceb68f2a0
commit
089429fee9
|
@ -173,6 +173,15 @@ private:
|
||||||
cmStringStream(const cmStringStream&);
|
cmStringStream(const cmStringStream&);
|
||||||
void operator=(const cmStringStream&);
|
void operator=(const cmStringStream&);
|
||||||
};
|
};
|
||||||
|
class cmInputStringStream: public std::istringstream
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
cmInputStringStream() {}
|
||||||
|
cmInputStringStream(const char* c) : std::istringstream(c) {}
|
||||||
|
private:
|
||||||
|
cmInputStringStream(const cmInputStringStream&);
|
||||||
|
void operator=(const cmInputStringStream&);
|
||||||
|
};
|
||||||
#else
|
#else
|
||||||
class cmStrStreamCleanup
|
class cmStrStreamCleanup
|
||||||
{
|
{
|
||||||
|
@ -201,6 +210,16 @@ private:
|
||||||
cmStringStream(const cmStringStream&);
|
cmStringStream(const cmStringStream&);
|
||||||
void operator=(const cmStringStream&);
|
void operator=(const cmStringStream&);
|
||||||
};
|
};
|
||||||
|
class cmInputStringStream: public std::istrstream
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
typedef std::istrstream Superclass;
|
||||||
|
cmInputStringStream(const char* c) : Superclass(c) {}
|
||||||
|
private:
|
||||||
|
cmInputStringStream(const cmInputStringStream&);
|
||||||
|
void operator=(const cmInputStringStream&);
|
||||||
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -18,8 +18,6 @@
|
||||||
#include "cmRegularExpression.h"
|
#include "cmRegularExpression.h"
|
||||||
#include "cmSystemTools.h"
|
#include "cmSystemTools.h"
|
||||||
|
|
||||||
#include <strstream>
|
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
|
|
||||||
|
@ -477,7 +475,7 @@ int ctest::BuildDirectory()
|
||||||
// 1 - error
|
// 1 - error
|
||||||
// > 1 - warning
|
// > 1 - warning
|
||||||
std::vector<int> markedLines;
|
std::vector<int> markedLines;
|
||||||
std::istrstream istr(coutput);
|
cmInputStringStream istr(coutput);
|
||||||
while(istr)
|
while(istr)
|
||||||
{
|
{
|
||||||
char buffer[1024];
|
char buffer[1024];
|
||||||
|
|
Loading…
Reference in New Issue