Skip to content

Commit

Permalink
Free arguments after executing isolate (2).
Browse files Browse the repository at this point in the history
(Correcting a mistake in previous commit.)
  • Loading branch information
rqu authored and Martin Kruliš committed Jan 4, 2021
1 parent 4e2852b commit 218f9b5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/sandbox/isolate_sandbox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -250,8 +250,8 @@ void isolate_sandbox::isolate_run(const std::string &binary, const std::vector<s
execvp(isolate_binary_.c_str(), args);

// Never reached
for(char **arg = args; *arg; arg++)
free(*arg);
for(char **arg = args; *arg; arg++) { free(*arg); }
delete[] args;

log_and_throw(logger_, "Exec returned to child: ", strerror(errno));
} break;
Expand Down

0 comments on commit 218f9b5

Please sign in to comment.