summaryrefslogtreecommitdiff
path: root/src/sysExec.h
diff options
context:
space:
mode:
authorChristian Pointner <equinox@anytun.org>2010-01-12 21:53:59 +0000
committerChristian Pointner <equinox@anytun.org>2010-01-12 21:53:59 +0000
commitb25f4dc131b9cd2b0575995d88f969627ce98ef6 (patch)
tree0c5f4c9c939c851cd2fc987f4ce0b4920ac25e50 /src/sysExec.h
parentcleanup (diff)
improved new SysExec cleanup
Diffstat (limited to 'src/sysExec.h')
-rw-r--r--src/sysExec.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/sysExec.h b/src/sysExec.h
index d5315e4..7aada56 100644
--- a/src/sysExec.h
+++ b/src/sysExec.h
@@ -49,14 +49,21 @@ class SysExec
SysExec(std::string const& script, StringVector const& args);
SysExec(std::string const& script, StringList const& env);
SysExec(std::string const& script, StringVector const& args, StringList const& env);
- void waitForScript();
~SysExec();
+
+ int waitForScript();
+ int getReturnCode() const;
+
+ static void waitAndDestroy(SysExec** s);
+
private:
void doExec(std::string const& script, StringVector const& args, StringList const& env);
+
std::string script_;
pid_t pid_;
int pipefd_;
bool closed_;
+ int return_code_;
};
#endif