diff options
| author | Rui Ueyama <ruiu@google.com> | 2017-09-05 21:17:32 +0000 |
|---|---|---|
| committer | Rui Ueyama <ruiu@google.com> | 2017-09-05 21:17:32 +0000 |
| commit | 2ea27186b4bac2a124aaef7788707d3b48c719a8 (patch) | |
| tree | 87f54254991a4b8fef1266ff78d42745cf098ecc /lld/COFF/DriverUtils.cpp | |
| parent | 8b80b328d1c0103b62a3af2b97dd392d22e2bc85 (diff) | |
| download | bcm5719-llvm-2ea27186b4bac2a124aaef7788707d3b48c719a8.tar.gz bcm5719-llvm-2ea27186b4bac2a124aaef7788707d3b48c719a8.zip | |
Use raw_string_ostream::str to get a result string.
Looks like raw_string_ostream is buffered. If we do not call `flush`
nor `str`, it is not guaranteed that a result string has all characters
that were written to it.
It wasn't failing on buildbots, but I could reproduce the issue on my
Windows workstation.
llvm-svn: 312577
Diffstat (limited to 'lld/COFF/DriverUtils.cpp')
| -rw-r--r-- | lld/COFF/DriverUtils.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lld/COFF/DriverUtils.cpp b/lld/COFF/DriverUtils.cpp index df600dd5243..cf7f95f20ca 100644 --- a/lld/COFF/DriverUtils.cpp +++ b/lld/COFF/DriverUtils.cpp @@ -357,7 +357,7 @@ static std::string createDefaultXml() { << " </dependency>\n"; } OS << "</assembly>\n"; - return Ret; + return OS.str(); } static Expected<std::unique_ptr<MemoryBuffer>> |

