Skip to content

bug(xargs): when -a is /dev/full, it do not error out instead allocates memory indefinetively #770

Description

@HackingRepo

Hi, findutils mainteners

we want let you known, when passing to -a, /dev/full, it just hangs and tries allocate massive memory, until killed, we confirmed using free -mh

relunsec@relunsec:~/software/findutils/target/debug$ sudo ./xargs -a /dev/full ls
^C

until killed by the linux kernel OOM or pressing CTRL+C, while the gnu correctly error out and abort not tries to allocate indefnitevly memory, unlike the uu find

relunsec@relunsec:~/software/findutils/target/debug$ sudo /bin/xargs -a /dev/full ls
/bin/xargs: WARNING: a NUL character occurred in the input.  It cannot be passed through in the argument list.  Did you mean to use the --null option?
/bin/xargs: argument line too long

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions