Skip to content

Commit 6d135c2

Browse files
committed
Remove warnings for Zero sized sections
We just don't care if we don't know where they go
1 parent 0d2a0a0 commit 6d135c2

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

tools/memap.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ def parse_object_name_gcc(self, line, prefixes):
166166
return '[lib]/' + object_name
167167

168168
else:
169-
print "Malformed input found when parsing GCC map: %s" % line
169+
print "Unknown object name found in GCC map file: %s" % line
170170
return '[misc]'
171171

172172
def parse_section_gcc(self, line, prefixes):
@@ -188,9 +188,10 @@ def parse_section_gcc(self, line, prefixes):
188188

189189
is_section = re.match(RE_STD_SECTION_GCC, line)
190190
if is_section:
191-
o_name = self.parse_object_name_gcc(is_section.group(3), prefixes)
192191
o_size = int(is_section.group(2), 16)
193-
return [o_name, o_size]
192+
if o_size:
193+
o_name = self.parse_object_name_gcc(is_section.group(3), prefixes)
194+
return [o_name, o_size]
194195

195196
return ["", 0]
196197

0 commit comments

Comments
 (0)