]> git.baikalelectronics.ru Git - kernel.git/commit
libbpf: preserve errno before calling into user callback
authorAndrii Nakryiko <andriin@fb.com>
Wed, 29 May 2019 17:36:04 +0000 (10:36 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Wed, 29 May 2019 23:23:34 +0000 (01:23 +0200)
commitbe5c5d4e9d8cbdd7fcdcbc45e86e34bc0bd1cefd
tree792ac7428a29e496e2ce8f5622e81570fa89872d
parent8ca990ce0d402d5aaf05f7a33ff025fcbcbb5f93
libbpf: preserve errno before calling into user callback

pr_warning ultimately may call into user-provided callback function,
which can clobber errno value, so we need to save it before that.

Acked-by: Song Liu <songliubraving@fb.com>
Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
tools/lib/bpf/libbpf.c