mirror of
https://github.com/yuzu-emu/breakpad.git
synced 2024-11-24 16:25:49 +01:00
The 'no_next_addr_count' variable in ComputeSizeAndRVA shouldn't be static.
The current arrangement would produce needless warnings if WriteSymbolFile were ever used twice in the same program invocation. Even if it weren't wrong, it's unnecessary, and local non-const static variables require extra care when reading to be sure of their effect. A=jimblandy R=nealsid git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@363 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
parent
722afebee0
commit
53cb8044fd
@ -444,6 +444,7 @@ static void AddIncludedFiles(struct SymbolInfo *symbols,
|
||||
// Compute size and rva information based on symbols loaded from stab section.
|
||||
static bool ComputeSizeAndRVA(ElfW(Addr) loading_addr,
|
||||
struct SymbolInfo *symbols) {
|
||||
int no_next_addr_count = 0;
|
||||
std::vector<struct SourceFileInfo *> sorted_files =
|
||||
SortByAddress(&(symbols->source_file_info));
|
||||
for (size_t i = 0; i < sorted_files.size(); ++i) {
|
||||
@ -476,7 +477,6 @@ static bool ComputeSizeAndRVA(ElfW(Addr) loading_addr,
|
||||
// }
|
||||
// TODO(liuli): Find a better solution.
|
||||
static const int kDefaultSize = 0x10000000;
|
||||
static int no_next_addr_count = 0;
|
||||
if (next_addr != 0) {
|
||||
func_info.size = next_addr - func_info.addr;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user