mirror of
https://github.com/hyprwm/hyprutils.git
synced 2025-05-12 21:30:36 +01:00
os/process: populate pid when ran sync
This commit is contained in:
parent
e4e018a2ca
commit
77d7ea3498
2 changed files with 3 additions and 2 deletions
|
@ -24,8 +24,7 @@ namespace Hyprutils {
|
|||
const std::string& stdOut();
|
||||
const std::string& stdErr();
|
||||
|
||||
// only populated when ran async
|
||||
const pid_t pid();
|
||||
const pid_t pid();
|
||||
|
||||
private:
|
||||
std::string binary, out, err;
|
||||
|
|
|
@ -72,6 +72,8 @@ bool Hyprutils::OS::CProcess::runSync() {
|
|||
out = "";
|
||||
err = "";
|
||||
|
||||
grandchildPid = pid;
|
||||
|
||||
std::array<char, 1024> buf;
|
||||
buf.fill(0);
|
||||
|
||||
|
|
Loading…
Reference in a new issue