Fix of Invoking prusa-slicer from $PATH environment variable crashes #5542
Also it likely fixes Crashes when started from symbolic link #5751
This commit is contained in:
parent
0369caa9e1
commit
293f85b6cf
1 changed files with 4 additions and 1 deletions
|
@ -28,6 +28,7 @@
|
|||
#include <boost/nowide/cenv.hpp>
|
||||
#include <boost/nowide/iostream.hpp>
|
||||
#include <boost/nowide/integration/filesystem.hpp>
|
||||
#include <boost/dll/runtime_symbol_info.hpp>
|
||||
|
||||
#include "unix/fhs.hpp" // Generated by CMake from ../platform/unix/fhs.hpp.in
|
||||
|
||||
|
@ -594,7 +595,9 @@ bool CLI::setup(int argc, char **argv)
|
|||
}
|
||||
}
|
||||
|
||||
boost::filesystem::path path_to_binary = boost::filesystem::system_complete(argv[0]);
|
||||
// See Invoking prusa-slicer from $PATH environment variable crashes #5542
|
||||
// boost::filesystem::path path_to_binary = boost::filesystem::system_complete(argv[0]);
|
||||
boost::filesystem::path path_to_binary = boost::dll::program_location();
|
||||
|
||||
// Path from the Slic3r binary to its resources.
|
||||
#ifdef __APPLE__
|
||||
|
|
Loading…
Reference in a new issue