Skip to content

bug(truncate): when using --reference with /var/run/snapd.socket no errors #12963

@HackingRepo

Description

@HackingRepo

Hi, uutils mainteners

we see when using --reference with /var/run/snapd.socket, no errors as out testing confirms

relunsec@relunsec:~/software/coreutils/target/debug$ ./truncate --reference /var/run/snapd.socket a
relunsec@relunsec:~/software/coreutils/target/debug$ echo $?
0
relunsec@relunsec:~/software/coreutils/target/debug$ gnutruncate --reference /var/run/snapd.socket a
gnutruncate: cannot get the size of '/var/run/snapd.socket': No such device or address
relunsec@relunsec:~/software/coreutils/target/debug$ echo $?
1
relunsec@relunsec:~/software/coreutils/target/debug$ 

as you can see the uu truncate no errors and exits with success, while the gnu one errors out to stderr and exits 1.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions