Init variables to avoid crashes.

This commit is contained in:
Mike Lischke 2016-11-20 15:53:00 +01:00
parent 469685df7b
commit 5d1858f502

View File

@ -40,8 +40,8 @@
// called by initChildren (calls initWithFile internally)
- (id) initWithFilename:(std::string&)filename command:(DylibCommand*)aCommand document:(MyDocument*)aDocument parent:(MachOModel*)aParent {
BOOL isWeakReference = (command && !command->isNecessary());
MachO* aFile;
MachOArchitecture* anArchitecture;
MachO* aFile = nullptr;
MachOArchitecture* anArchitecture = nullptr;
state = StateNormal;
try {
aFile = [aDocument cache]->getFile(filename, aParent->file); // throws exception in case file is not found