mirror of
				https://github.com/hedge-dev/XenonRecomp.git
				synced 2025-11-04 06:47:09 +00:00 
			
		
		
		
	Check if function call is within the same section.
This commit is contained in:
		@@ -183,9 +183,9 @@ int main(int argc, char* argv[])
 | 
				
			|||||||
            {
 | 
					            {
 | 
				
			||||||
                size_t address = base + (data - section.data) + PPC_BI(insn);
 | 
					                size_t address = base + (data - section.data) + PPC_BI(insn);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                if (image.symbols.find(address) == image.symbols.end())
 | 
					                if (address >= section.base && address < section.base + section.size && image.symbols.find(address) == image.symbols.end())
 | 
				
			||||||
                {
 | 
					                {
 | 
				
			||||||
                    auto& fn = functions.emplace_back(Function::Analyze(section.data + address - section.base, section.size - (address - section.base), address));
 | 
					                    auto& fn = functions.emplace_back(Function::Analyze(section.data + address - section.base, section.base + section.size - address, address));
 | 
				
			||||||
                    hardcodedFuncCheck(fn);
 | 
					                    hardcodedFuncCheck(fn);
 | 
				
			||||||
                    image.symbols.emplace(std::format("sub_{:X}", fn.base), fn.base, fn.size, Symbol_Function);
 | 
					                    image.symbols.emplace(std::format("sub_{:X}", fn.base), fn.base, fn.size, Symbol_Function);
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user