mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[serialization] Don't keep a ModuleFile around when missing dependencies.
All we need is the skeleton Module to let us know not to try again. This was previously leading to a use-after-free, caught by Guard Malloc. Thanks, Argyrios! Swift SVN r6267
This commit is contained in:
@@ -211,6 +211,8 @@ Module *SerializedModuleLoader::loadModule(SourceLoc importLoc,
|
||||
diag::serialization_missing_dependencies,
|
||||
missingNames);
|
||||
}
|
||||
|
||||
module->File = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user