From: Nick Alcock Date: Mon, 15 Jul 2024 20:05:43 +0000 (+0100) Subject: libctf, open: Fix enum error handling path X-Git-Tag: gdb-16-branchpoint~1266 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=4cd2c266cf35382b690da27482368cd80c3a71ef;p=thirdparty%2Fbinutils-gdb.git libctf, open: Fix enum error handling path This new error-handling path was not properly initializing the fp's errno. libctf/ * ctf-open.c (init_static_types_internal): Set errno properly. --- diff --git a/libctf/ctf-open.c b/libctf/ctf-open.c index fd6d36edc46..ab97cde3ebf 100644 --- a/libctf/ctf-open.c +++ b/libctf/ctf-open.c @@ -1066,6 +1066,7 @@ init_static_types_internal (ctf_dict_t *fp, ctf_header_t *cth, continue; enum_err: + ctf_set_errno (fp, err); ctf_next_destroy (i_constants); ctf_next_destroy (i); return ctf_errno (fp);