Commit 34083d99 authored by Oleg Korshul's avatar Oleg Korshul

preload cef library

parent ef965718
......@@ -391,10 +391,11 @@ int CHtmlFile::Convert(const std::vector<std::wstring>& arFiles, const std::wstr
nargs[0] = sXmlA.c_str();
nargs[1] = NULL;
const char* nenv[3];
const char* nenv[4];
nenv[0] = sLibraryDir.c_str();
nenv[1] = "DISPLAY=:0";
nenv[2] = NULL;
nenv[1] = "LD_PRELOAD=./libcef.so";
nenv[2] = "DISPLAY=:0";
nenv[3] = NULL;
execve(sProgramm.c_str(),
(char * const *)nargs,
......@@ -411,10 +412,11 @@ int CHtmlFile::Convert(const std::vector<std::wstring>& arFiles, const std::wstr
nargs[4] = sXmlA.c_str();
nargs[5] = NULL;
const char* nenv[3];
const char* nenv[4];
nenv[0] = sLibraryDir.c_str();
nenv[1] = NULL;//"DISPLAY=:99";
nenv[2] = NULL;
nenv[1] = "LD_PRELOAD=./libcef.so";
nenv[2] = NULL;//"DISPLAY=:99";
nenv[3] = NULL;
execve("/usr/bin/xvfb-run", (char * const *)nargs, (char * const *)nenv);
exit(EXIT_SUCCESS);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment