aboutsummaryrefslogtreecommitdiff
path: root/ld/testplug3.c
diff options
context:
space:
mode:
Diffstat (limited to 'ld/testplug3.c')
-rw-r--r--ld/testplug3.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/ld/testplug3.c b/ld/testplug3.c
index 05fdca0..928f4d6 100644
--- a/ld/testplug3.c
+++ b/ld/testplug3.c
@@ -217,12 +217,15 @@ parse_symdefstr (const char *str, struct ld_plugin_symbol *sym)
/* Finally we'll use sscanf to parse the numeric fields, then
we'll split out the strings which we need to allocate separate
storage for anyway so that we can add nul termination. */
- n = sscanf (colon2 + 1, "%i:%i:%lli", &sym->def, &sym->visibility, &size);
+ n = sscanf (colon2 + 1, "%hhi:%i:%lli", &sym->def, &sym->visibility, &size);
if (n != 3)
return LDPS_ERR;
/* Parsed successfully, so allocate strings and fill out fields. */
sym->size = size;
+ sym->unused = 0;
+ sym->section_kind = 0;
+ sym->symbol_type = 0;
sym->resolution = LDPR_UNKNOWN;
sym->name = malloc (colon1 - str + 1);
if (!sym->name)