diff options
author | Lennart Poettering <lennart@poettering.net> | 2013-11-07 21:06:44 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2013-11-07 21:06:44 +0100 |
commit | 46e65dcc3a522b5e992e165b5e61d14254026859 (patch) | |
tree | 84ea0d49f1c502972e8bfa85587cfbf9c875b586 /src/shared | |
parent | 0d49cfa264e8afc52526cd0cd73b2309dff498b2 (diff) |
polkit: don't spawn local client if we access a remote system
Diffstat (limited to 'src/shared')
-rw-r--r-- | src/shared/pager.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/shared/pager.c b/src/shared/pager.c index 8dddf24f4c..9fa611479c 100644 --- a/src/shared/pager.c +++ b/src/shared/pager.c @@ -34,13 +34,16 @@ static pid_t pager_pid = 0; _noreturn_ static void pager_fallback(void) { ssize_t n; + do { n = splice(STDIN_FILENO, NULL, STDOUT_FILENO, NULL, 64*1024, 0); } while (n > 0); + if (n < 0) { log_error("Internal pager failed: %m"); _exit(EXIT_FAILURE); } + _exit(EXIT_SUCCESS); } |