]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-96678: Avoid undefined behaviour in test (#96672)
authorMatthias Görgens <matthias.goergens@gmail.com>
Tue, 13 Sep 2022 12:15:11 +0000 (20:15 +0800)
committerGitHub <noreply@github.com>
Tue, 13 Sep 2022 12:15:11 +0000 (13:15 +0100)
Programs/_testembed.c

index f84445690eb8f6b5679dc4c8446d41766ee417f7..a2a2ff40b2774b5799d825ebe9e831b6f451635a 100644 (file)
@@ -1581,7 +1581,7 @@ static int test_init_is_python_build(void)
     config._is_python_build = INT_MAX;
     env = getenv("NEGATIVE_ISPYTHONBUILD");
     if (env && strcmp(env, "0") != 0) {
-        config._is_python_build++;
+        config._is_python_build = INT_MIN;
     }
     init_from_config_clear(&config);
     Py_Finalize();