aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMathias Gumz <akira at fluxbox dot org>2008-01-25 07:21:35 (GMT)
committerMathias Gumz <akira at fluxbox dot org>2008-01-25 07:21:35 (GMT)
commit65df54d635e8ad2029efea1c3c00eccfffe8532d (patch)
tree98a1b6181d90af56fb735b3c92bc737c2c019e25 /src
parent70a24b992ccd4082e00396bdb89ec02dec7e6ec5 (diff)
downloadfluxbox-65df54d635e8ad2029efea1c3c00eccfffe8532d.zip
fluxbox-65df54d635e8ad2029efea1c3c00eccfffe8532d.tar.bz2
std::string.c_str() is never NULL
Diffstat (limited to 'src')
-rw-r--r--src/main.cc7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/main.cc b/src/main.cc
index ae2b98c..9da51ec 100644
--- a/src/main.cc
+++ b/src/main.cc
@@ -325,11 +325,8 @@ int main(int argc, char **argv) {
325 if (!shell) 325 if (!shell)
326 shell = "/bin/sh"; 326 shell = "/bin/sh";
327 327
328 const char *arg = restart_argument.c_str(); 328 execlp(shell, shell, "-c", restart_argument.c_str(), (const char *) NULL);
329 if (arg) { 329 perror(restart_argument.c_str());
330 execlp(shell, shell, "-c", arg, (const char *) NULL);
331 perror(arg);
332 }
333 } 330 }
334 331
335 // fall back in case the above execlp doesn't work 332 // fall back in case the above execlp doesn't work