Fixing analysis regression: don't analyze on gets during analysis pass.
This commit is contained in:
parent
f94256aaaf
commit
6b851da9d7
|
@ -153,7 +153,7 @@ int ExecModule::Init() {
|
||||||
}
|
}
|
||||||
|
|
||||||
FunctionSymbol* ExecModule::FindFunctionSymbol(uint32_t address) {
|
FunctionSymbol* ExecModule::FindFunctionSymbol(uint32_t address) {
|
||||||
return sdb_->GetFunction(address);
|
return sdb_->GetFunction(address, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ExecModule::Dump() {
|
void ExecModule::Dump() {
|
||||||
|
|
|
@ -147,7 +147,7 @@ VariableSymbol* SymbolDatabase::GetOrInsertVariable(uint32_t address) {
|
||||||
return var;
|
return var;
|
||||||
}
|
}
|
||||||
|
|
||||||
FunctionSymbol* SymbolDatabase::GetFunction(uint32_t address) {
|
FunctionSymbol* SymbolDatabase::GetFunction(uint32_t address, bool analyze) {
|
||||||
SymbolMap::iterator i = symbols_.find(address);
|
SymbolMap::iterator i = symbols_.find(address);
|
||||||
if (i != symbols_.end() && i->second->symbol_type == Symbol::Function) {
|
if (i != symbols_.end() && i->second->symbol_type == Symbol::Function) {
|
||||||
return static_cast<FunctionSymbol*>(i->second);
|
return static_cast<FunctionSymbol*>(i->second);
|
||||||
|
@ -161,7 +161,9 @@ FunctionSymbol* SymbolDatabase::GetFunction(uint32_t address) {
|
||||||
symbols_.insert(SymbolMap::value_type(address, fn));
|
symbols_.insert(SymbolMap::value_type(address, fn));
|
||||||
scan_queue_.push_back(fn);
|
scan_queue_.push_back(fn);
|
||||||
|
|
||||||
FlushQueue();
|
if (analyze) {
|
||||||
|
FlushQueue();
|
||||||
|
}
|
||||||
|
|
||||||
return fn;
|
return fn;
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,7 +39,7 @@ public:
|
||||||
FunctionSymbol* GetOrInsertFunction(
|
FunctionSymbol* GetOrInsertFunction(
|
||||||
uint32_t address, FunctionSymbol* opt_call_source = NULL);
|
uint32_t address, FunctionSymbol* opt_call_source = NULL);
|
||||||
VariableSymbol* GetOrInsertVariable(uint32_t address);
|
VariableSymbol* GetOrInsertVariable(uint32_t address);
|
||||||
FunctionSymbol* GetFunction(uint32_t address);
|
FunctionSymbol* GetFunction(uint32_t address, bool analyze = false);
|
||||||
VariableSymbol* GetVariable(uint32_t address);
|
VariableSymbol* GetVariable(uint32_t address);
|
||||||
|
|
||||||
int GetAllVariables(std::vector<VariableSymbol*>& variables);
|
int GetAllVariables(std::vector<VariableSymbol*>& variables);
|
||||||
|
|
Loading…
Reference in New Issue