From d5018973e368b53f7dc4425b4d68360dce5f90b5 Mon Sep 17 00:00:00 2001 From: Changcheng Liu Date: Sat, 13 Apr 2019 14:06:52 +0800 Subject: [PATCH] denc: fix build error by calling global snprintf The snprintf in local namespace only need 3 parameters which doesn't match the call function protertype here. Fix the build error by calling global snprintf. Signed-off-by: Changcheng Liu --- src/include/denc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/include/denc.h b/src/include/denc.h index c9a86cfb0d9d..7d4839224a55 100644 --- a/src/include/denc.h +++ b/src/include/denc.h @@ -94,7 +94,7 @@ inline constexpr bool denc_supported = denc_traits::supported; if (bits > 2) \ break; \ char fn[PATH_MAX]; \ - snprintf(fn, sizeof(fn), \ + ::snprintf(fn, sizeof(fn), \ ENCODE_STRINGIFY(ENCODE_DUMP_PATH) "/%s__%d.%x", #Type, \ getpid(), i++); \ int fd = ::open(fn, O_WRONLY|O_TRUNC|O_CREAT|O_CLOEXEC, 0644); \ -- 2.47.3