]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
scripts/decodecode: return 0 on success
authorPatrick Bellasi <derkling@google.com>
Wed, 18 Mar 2026 15:05:45 +0000 (15:05 +0000)
committerAndrew Morton <akpm@linux-foundation.org>
Sat, 28 Mar 2026 04:19:48 +0000 (21:19 -0700)
commitb8822d73d6fe0d43de3b98ccc995b7032993b1b7
tree395158d65490871c746f72dd8d09e8eaeef66ef1
parent0f8e38eeb995bf818a7f220de109d6b6b96038b4
scripts/decodecode: return 0 on success

The decodecode script always returns an exit code of 1, regardless of
whether the operation was successful or not.  This is because the
"cleanup" function, which is registered to run on any script exit via
"trap cleanup EXIT", contains an unconditional "exit 1".

Remove the "exit 1" from the "cleanup" function so that it only performs
the necessary file cleanup without forcing a non-zero exit status.

Do that to ensure successful script executions now exit with code 0.
Exits due to errors are all handled by the "die()" function and will still
correctly exit with code 1.

Link: https://lkml.kernel.org/r/20260318150545.2809311-1-derkling@google.com
Signed-off-by: Patrick Bellasi <derkling@google.com>
Acked-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
scripts/decodecode