From 56ba48d705908c67e3aecba992d91cff2071f68e Mon Sep 17 00:00:00 2001 From: Dmitry-Me Date: Thu, 9 Nov 2017 16:25:56 +0300 Subject: [PATCH] Unify code handling "x" and "u" scanf specifiers --- lib/checkio.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/checkio.cpp b/lib/checkio.cpp index 6a570e5e0..d3b789d74 100644 --- a/lib/checkio.cpp +++ b/lib/checkio.cpp @@ -941,8 +941,8 @@ void CheckIO::checkFormatString(const Token * const tok, if (argInfo.typeToken->str() != "int") invalidScanfArgTypeError_int(tok, numFormat, specifier, &argInfo, true); else if (typesMatch(argInfo.typeToken->originalName(), "size_t") || - typesMatch(argInfo.typeToken->originalName(), "ssize_t") || - argInfo.typeToken->originalName() == "uintmax_t") + typesMatch(argInfo.typeToken->originalName(), "ptrdiff_t") || + typesMatch(argInfo.typeToken->originalName(), "uintmax_t")) invalidScanfArgTypeError_int(tok, numFormat, specifier, &argInfo, true); break; }