diff options
| author | 2017-11-08 10:17:15 +0100 | |
|---|---|---|
| committer | 2017-11-08 10:17:15 +0100 | |
| commit | 8a103df440afea30c91ebd42e61dc644e647f4bd (patch) | |
| tree | 2cfa99e9c6e1e138e1404bce4294e46cb0034cce /tools/objtool/check.c | |
| parent | sched/sysctl: Fix attributes of some extern declarations (diff) | |
| parent | drivers/ide-cd: Handle missing driver data during status check gracefully (diff) | |
| download | linux-dev-8a103df440afea30c91ebd42e61dc644e647f4bd.tar.xz linux-dev-8a103df440afea30c91ebd42e61dc644e647f4bd.zip | |
Merge branch 'linus' into sched/core, to pick up fixes
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'tools/objtool/check.c')
| -rw-r--r-- | tools/objtool/check.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/tools/objtool/check.c b/tools/objtool/check.c index a0c518ecf085..c0e26ad1fa7e 100644 --- a/tools/objtool/check.c +++ b/tools/objtool/check.c @@ -267,12 +267,13 @@ static int decode_instructions(struct objtool_file *file) &insn->immediate, &insn->stack_op); if (ret) - return ret; + goto err; if (!insn->type || insn->type > INSN_LAST) { WARN_FUNC("invalid instruction type %d", insn->sec, insn->offset, insn->type); - return -1; + ret = -1; + goto err; } hash_add(file->insn_hash, &insn->hash, insn->offset); @@ -296,6 +297,10 @@ static int decode_instructions(struct objtool_file *file) } return 0; + +err: + free(insn); + return ret; } /* |
