mirror of
https://github.com/jarun/nnn.git
synced 2024-11-24 11:51:27 +00:00
Fix #219
This commit is contained in:
parent
764c1fe60c
commit
3f262910d3
|
@ -976,11 +976,11 @@ static void spawn(const char *file, const char *arg1, const char *arg2, const ch
|
||||||
arg2 = tmp;
|
arg2 = tmp;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pid = fork();
|
||||||
|
if (pid == 0) {
|
||||||
if (flag & F_NORMAL)
|
if (flag & F_NORMAL)
|
||||||
exitcurses();
|
exitcurses();
|
||||||
|
|
||||||
pid = fork();
|
|
||||||
if (pid == 0) {
|
|
||||||
if (dir != NULL)
|
if (dir != NULL)
|
||||||
status = chdir(dir);
|
status = chdir(dir);
|
||||||
|
|
||||||
|
@ -1017,10 +1017,13 @@ static void spawn(const char *file, const char *arg1, const char *arg2, const ch
|
||||||
DPRINTF_D(status);
|
DPRINTF_D(status);
|
||||||
|
|
||||||
DPRINTF_D(pid);
|
DPRINTF_D(pid);
|
||||||
if (flag & F_NORMAL)
|
if (flag & F_NORMAL) {
|
||||||
|
exitcurses();
|
||||||
|
initcurses();
|
||||||
refresh();
|
refresh();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Quotes argument and spawns a shell command
|
* Quotes argument and spawns a shell command
|
||||||
|
|
Loading…
Reference in a new issue