Mercurial > public > mercurial-scm > hg
diff contrib/fuzz/manifest.cc @ 40146:adfe4bb53a47
fuzz: try setting PYTHONNOUSERSITE=1 to avoid loading site-packages
Right now the fuzzer is crashing trying to look up the home dir for
uid 0, which is breaking in the fuzz environment.
Differential Revision: https://phab.mercurial-scm.org/D4936
author | Augie Fackler <augie@google.com> |
---|---|
date | Thu, 11 Oct 2018 07:27:24 -0400 |
parents | ca4a32d0a4d6 |
children | 170cd2a5a1da |
line wrap: on
line diff
--- a/contrib/fuzz/manifest.cc Wed Oct 03 10:46:56 2018 +0200 +++ b/contrib/fuzz/manifest.cc Thu Oct 11 07:27:24 2018 -0400 @@ -30,6 +30,7 @@ } strncpy(cpypath, pypath.c_str(), pypath.size()); setenv("PYTHONPATH", cpypath, 1); + setenv("PYTHONNOUSERSITE", "1", 1); Py_SetPythonHome(cpypath); Py_InitializeEx(0); return 0;