From 3524a0a3ebc6396b290b521723e7130cc3c8ea0a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Mon, 3 Jan 2022 20:55:46 +0100 Subject: [PATCH] exprengine: reduce max buffer size to int_max --- lib/exprengine.cpp | 2 +- test/testexprengine.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/exprengine.cpp b/lib/exprengine.cpp index 2efd6e4a9..bfb2a150f 100644 --- a/lib/exprengine.cpp +++ b/lib/exprengine.cpp @@ -150,7 +150,7 @@ #define Z3_VERSION_INT GET_VERSION_INT(Z3_MAJOR_VERSION, Z3_MINOR_VERSION, Z3_BUILD_NUMBER) #endif -const std::uint64_t MAX_BUFFER_SIZE = ~0ULL; +const uint32_t MAX_BUFFER_SIZE = ~0U >> 1; #define CONTRACT 1 namespace { diff --git a/test/testexprengine.cpp b/test/testexprengine.cpp index 9b4d01e17..5142e87be 100644 --- a/test/testexprengine.cpp +++ b/test/testexprengine.cpp @@ -814,7 +814,7 @@ private: " *x = 1;\n" "}"; ASSERT_EQUALS("1:28: $2=ArrayValue([$1],[:]=?,null)\n" - "1:28: $1=IntRange(1:ffffffffffffffff)\n" + "1:28: $1=IntRange(1:2147483647)\n" "1:28: D0:memory:{x=($2,[$1],[:]=?)}\n" "2:9: D0:memory:{x=($2,[$1],[:]=?,[0]=2)}\n" "3:9: D0:memory:{x=($2,[$1],[:]=?,[0]=1)}\n",