tools: build: fix handing of "--stats-depth"

The introduction of pretty-bar had broken the handling of
"mbed compile"'s "--stats-depth" argument. No matter what one gave
as parameter to it, the result output is just using the default 2.
Fix the logic in build_api.
pull/6083/head
Tero Jääskö 2018-02-13 15:15:31 +02:00
parent ccff46d9a3
commit faabde13a1
1 changed files with 1 additions and 1 deletions

View File

@ -528,7 +528,7 @@ def build_project(src_paths, build_path, target, toolchain_name,
memap_instance = getattr(toolchain, 'memap_instance', None)
memap_table = ''
if memap_instance:
real_stats_depth = stats_depth if stats_depth is None else 2
real_stats_depth = stats_depth if stats_depth is not None else 2
memap_table = memap_instance.generate_output('table', real_stats_depth)
if not silent:
if not stats_depth: