bpf: Use isdigit() in bpf_bprintf_prepare()
PATCH 1/1 bpf: Use isdigit() in bpf_bprintf_prepare()
Use isdigit() to replace the open-coded implementation.
Signed-off-by Thorsten Blum <[email protected]>
--- kernel/bpf/helpers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
kernel/bpf/helpers.c +1 -1
@@ -927,7 +927,7 @@ int bpf_bprintf_prepare(const char *fmt, u32 fmt_size, const u64 *raw_args, i++;if (fmt[i] >='1' && fmt[i] <='9' ) { i++; -while (fmt[i] >='0' && fmt[i] <='9' ) +while (isdigit (fmt[i])) i++; }