mirror of
https://github.com/jarun/nnn.git
synced 2024-11-24 11:51:27 +00:00
Increase pipe capacity
This commit is contained in:
parent
d71379e5b6
commit
151bbf000d
|
@ -4312,6 +4312,15 @@ static bool run_selected_plugin(char **path, const char *file, char *runfile, ch
|
||||||
if (fd == -1)
|
if (fd == -1)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
|
#ifdef __linux__
|
||||||
|
DPRINTF_D(fcntl(fd, F_GETPIPE_SZ));
|
||||||
|
/* Increase the pipe buffer size to 1 MB */
|
||||||
|
if (fcntl(fd, F_SETPIPE_SZ, 1024*1024) == -1) {
|
||||||
|
DPRINTF_S(strerror(errno));
|
||||||
|
}
|
||||||
|
DPRINTF_D(fcntl(fd, F_GETPIPE_SZ));
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Run plugin from command */
|
/* Run plugin from command */
|
||||||
if (*file == '_')
|
if (*file == '_')
|
||||||
run_cmd_as_plugin(*path, file, runfile);
|
run_cmd_as_plugin(*path, file, runfile);
|
||||||
|
|
Loading…
Reference in a new issue