File tree Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Expand file tree Collapse file tree 1 file changed +13
-5
lines changed Original file line number Diff line number Diff line change @@ -1854,18 +1854,26 @@ def map_elfs(project, logger=None):
1854
1854
def get_elf_file_dwarf_paths (location ):
1855
1855
"""Retrieve dwarf paths for ELF files."""
1856
1856
paths = get_dwarf_paths (location )
1857
- return {
1858
- "dwarf_compiled_paths" : paths .get ("compiled_paths" ) or [],
1859
- "dwarf_included_paths" : paths .get ("included_paths" ) or [],
1860
- }
1857
+ compiled_paths = paths .get ("compiled_paths" ) or []
1858
+ included_paths = (paths .get ("included_paths" ) or [],)
1859
+ dwarf_paths = {}
1860
+ if compiled_paths :
1861
+ dwarf_paths ["dwarf_compiled_paths" ] = compiled_paths
1862
+ if included_paths :
1863
+ dwarf_paths ["dwarf_included_paths" ] = included_paths
1864
+ return dwarf_paths
1861
1865
1862
1866
1863
1867
def get_go_file_paths (location ):
1864
1868
"""Retrieve Go file paths."""
1865
1869
go_symbols = (
1866
1870
collect_and_parse_symbols (location , check_type = False ).get ("go_symbols" ) or {}
1867
1871
)
1868
- return {"go_file_paths" : go_symbols .get ("file_paths" ) or []}
1872
+ file_paths = {}
1873
+ go_file_paths = go_symbols .get ("file_paths" ) or []
1874
+ if go_file_paths :
1875
+ file_paths ["go_file_paths" ] = go_file_paths
1876
+ return file_paths
1869
1877
1870
1878
1871
1879
def map_go_paths (project , logger = None ):
You can’t perform that action at this time.
0 commit comments