Support filename rewrite in backends

Signed-off-by: Ben Widawsky <[email protected]>
This commit is contained in:
Ben Widawsky
2019-06-18 14:39:52 -07:00
parent 468c41d997
commit 4a18e19fb8
4 changed files with 4 additions and 0 deletions
+1
View File
@@ -336,6 +336,7 @@ struct ProtobufPass : public Pass {
std::stringstream buf;
if (!filename.empty()) {
rewrite_filename(filename);
std::ofstream *ff = new std::ofstream;
ff->open(filename.c_str(), std::ofstream::trunc);
if (ff->fail()) {