Diffstat (limited to 'noncore/settings/aqpkg/mem.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/settings/aqpkg/mem.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/noncore/settings/aqpkg/mem.cpp b/noncore/settings/aqpkg/mem.cpp index 5f32a26..4c6117b 100644 --- a/noncore/settings/aqpkg/mem.cpp +++ b/noncore/settings/aqpkg/mem.cpp | |||
@@ -78,33 +78,33 @@ void AddTrack(long addr, long asize, const char *fname, long lnum) | |||
78 | allocList.insert(allocList.begin(), info); | 78 | allocList.insert(allocList.begin(), info); |
79 | }; | 79 | }; |
80 | 80 | ||
81 | void RemoveTrack(long addr) | 81 | void RemoveTrack(long addr) |
82 | { | 82 | { |
83 | AllocList::iterator i; | 83 | AllocList::iterator i; |
84 | 84 | ||
85 | bool found = false; | 85 | bool found = false; |
86 | for(i = allocList.begin(); i != allocList.end(); i++) | 86 | for(i = allocList.begin(); i != allocList.end(); i++) |
87 | { | 87 | { |
88 | if((*i)->address == addr) | 88 | if((*i)->address == addr) |
89 | { | 89 | { |
90 | allocList.remove((*i)); | 90 | allocList.remove((*i)); |
91 | found = true; | 91 | found = true; |
92 | break; | 92 | break; |
93 | } | 93 | } |
94 | } | 94 | } |
95 | } | 95 | } |
96 | 96 | ||
97 | void DumpUnfreed() | 97 | void DumpUnfreed() |
98 | { | 98 | { |
99 | AllocList::iterator i; | 99 | AllocList::iterator i; |
100 | long totalSize = 0; | 100 | long totalSize = 0; |
101 | char buf[1024]; | 101 | char buf[1024]; |
102 | 102 | // Debug output, okay to leave untranslated | |
103 | for(i = allocList.begin(); i != allocList.end(); i++) { | 103 | for(i = allocList.begin(); i != allocList.end(); i++) { |
104 | sprintf(buf, "%-15s: LINE %ld, ADDRESS %ld %ld unfreed", | 104 | sprintf(buf, "%-15s: LINE %ld, ADDRESS %ld %ld unfreed", |
105 | (*i)->file, (*i)->line, (*i)->address, (*i)->size); | 105 | (*i)->file, (*i)->line, (*i)->address, (*i)->size); |
106 | totalSize += (*i)->size; | 106 | totalSize += (*i)->size; |
107 | } | 107 | } |
108 | sprintf(buf, "-----------------------------------------------------------\n"); | 108 | sprintf(buf, "-----------------------------------------------------------\n"); |
109 | sprintf(buf, "Total Unfreed: %ld bytes\n", totalSize); | 109 | sprintf(buf, "Total Unfreed: %ld bytes\n", totalSize); |
110 | }; | 110 | }; |