[lldb/Reproducers] Always record the current working directory
Setting the current working directory in the VFS will fail if the given path doesn't exist in the YAML mapping or on disk.
This commit is contained in:
@@ -234,7 +234,10 @@ const char *SBReproducer::GetPath() {
|
||||
|
||||
void SBReproducer::SetWorkingDirectory(const char *path) {
|
||||
if (auto *g = lldb_private::repro::Reproducer::Instance().GetGenerator()) {
|
||||
g->GetOrCreate<WorkingDirectoryProvider>().Update(path);
|
||||
auto &wp = g->GetOrCreate<repro::WorkingDirectoryProvider>();
|
||||
wp.Update(path);
|
||||
auto &fp = g->GetOrCreate<repro::FileProvider>();
|
||||
fp.RecordInterestingDirectory(wp.GetWorkingDirectory());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user