summaryrefslogtreecommitdiff
path: root/app/cwm/kbfunc.c
diff options
context:
space:
mode:
authorOkan Demirmen <okan@cvs.openbsd.org>2012-10-31 19:30:20 +0000
committerOkan Demirmen <okan@cvs.openbsd.org>2012-10-31 19:30:20 +0000
commit17cb53f9b11452cfdeefa8e6cb8e2d749aaa22ad (patch)
treef1abb4670fd1f503cea2dd7e67ad4c1d2da9010b /app/cwm/kbfunc.c
parent39ac1b1cfdfa103f5959bb2c021f5dbf9d0db26b (diff)
replace 'reload' with 'restart', which merely re-exec's cwm using the
existing argv; same idea with respect to argv saving as Alexander Polakov. reload support was half-complete and is getting in the way. agreed to by many
Diffstat (limited to 'app/cwm/kbfunc.c')
-rw-r--r--app/cwm/kbfunc.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/app/cwm/kbfunc.c b/app/cwm/kbfunc.c
index 77544927b..67f7a21ae 100644
--- a/app/cwm/kbfunc.c
+++ b/app/cwm/kbfunc.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: kbfunc.c,v 1.63 2012/09/09 19:47:47 okan Exp $
+ * $OpenBSD: kbfunc.c,v 1.64 2012/10/31 19:30:19 okan Exp $
*/
#include <sys/param.h>
@@ -35,6 +35,7 @@
#define KNOWN_HOSTS ".ssh/known_hosts"
#define HASH_MARKER "|1|"
+extern char **cwm_argv;
extern sig_atomic_t xev_quit;
void
@@ -490,7 +491,8 @@ kbfunc_quit_wm(struct client_ctx *cc, union arg *arg)
}
void
-kbfunc_reload(struct client_ctx *cc, union arg *arg)
+kbfunc_restart(struct client_ctx *cc, union arg *arg)
{
- conf_reload(&Conf);
+ (void)setsid();
+ (void)execvp(cwm_argv[0], cwm_argv);
}