Skip to content

Commit

Permalink
Fix: mkdtemp is not available for macOS
Browse files Browse the repository at this point in the history
  • Loading branch information
fdabrandao committed Feb 23, 2024
1 parent cea9470 commit dac7296
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions nl-writer2/src/nl-solver.cc
Original file line number Diff line number Diff line change
Expand Up @@ -554,6 +554,9 @@ void NLSolver::InitAutoStub() {
if (!std::filesystem::create_directory(pathstr_))
Utils().myexit("Could not create temp dir '"
+ pathstr_ + "'");
#elif __APPLE__
if (!std::filesystem::create_directory(pathstr_))
Utils().myexit("Could not create temp dir '" + pathstr_ + "'");
#else
if (!mkdtemp((char*)pathstr_.c_str()))
Utils().myexit("Could not create a temp dir\n"
Expand Down

0 comments on commit dac7296

Please sign in to comment.