Re: [PATCH 1/4] support Dash as default shell

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jun 14, 2022 at 12:21 PM Christian Göttsche
<cgzones@xxxxxxxxxxxxxx> wrote:
> Debian uses Dash as default shell and switching via
>
>     dpkg-reconfigure dash
>
> has become deprecated.
>
> * Use POSIX compliant `> target 2>&1` instead of `>& target`.

I'm fine with this subset of changes.

> * Call runcon directly to avoid a fork within Dash, which breaks tests
>   requiring to not change the PID of executing commands

I don't seem to have such problem when I change the default shell to
dash on Fedora. Can you provide a minimal reproducer?

> * Use bash explicitly for non POSIX read option -t

I'd like to try to find some nicer alternative for this one first...
If I don't find one, then yours will have to do, I guess.

Any specific reason why you used `` instead of system()? AFAIK the
only difference is that `` return the command's stdout as a string,
while system() returns the exit code and forwards stdout.

>
> Signed-off-by: Christian Göttsche <cgzones@xxxxxxxxxxxxxx>
> ---
>  README.md                      |  7 -------
>  tests/binder/test              |  2 +-
>  tests/bpf/test                 |  4 ++--
>  tests/fdreceive/test           |  2 +-
>  tests/filesystem/Filesystem.pm | 14 +++++++-------
>  tests/inet_socket/test         |  2 +-
>  tests/ptrace/test              |  6 +++---
>  tests/sctp/test                |  2 +-
>  tests/sigkill/test             |  2 +-
>  tests/task_getpgid/test        |  6 +++---
>  tests/task_getscheduler/test   |  6 +++---
>  tests/task_getsid/test         |  6 +++---
>  tests/task_setnice/test        |  6 +++---
>  tests/task_setscheduler/test   |  6 +++---
>  tests/unix_socket/test         |  2 +-
>  tests/vsock_socket/test        |  2 +-
>  16 files changed, 34 insertions(+), 41 deletions(-)
>
(snip)

--
Ondrej Mosnacek
Software Engineer, Linux Security - SELinux kernel
Red Hat, Inc.





[Index of Archives]     [Selinux Refpolicy]     [Linux SGX]     [Fedora Users]     [Fedora Desktop]     [Yosemite Photos]     [Yosemite Camping]     [Yosemite Campsites]     [KDE Users]     [Gnome Users]

  Powered by Linux