Page MenuHomeFreeBSD

PR228448: `unlink -foo` , the original use of `unlink`, no longer works.
ClosedPublic

Authored by yuripv on Sep 12 2018, 12:58 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Mar 11, 4:16 PM
Unknown Object (File)
Mon, Mar 11, 4:15 PM
Unknown Object (File)
Mon, Mar 11, 4:15 PM
Unknown Object (File)
Fri, Mar 8, 2:15 AM
Unknown Object (File)
Jan 9 2024, 12:07 AM
Unknown Object (File)
Jan 4 2024, 3:31 PM
Unknown Object (File)
Jan 4 2024, 3:31 PM
Unknown Object (File)
Jan 4 2024, 3:31 PM
Subscribers

Details

Summary

Restore the original behavior of unlink(1), passing the provided filename
directly to unlink(2), handling the first argument being "--" correctly.

This fixes the unlink -foo, broken in r97533.

Reported by: Brennan Vincent <brennan@umanwizard.com>
Submitted by: Brennan Vincent <brennan@umanwizard.com>
PR: 228448

Test Plan

$ kyua test -k /usr/tests/Kyuafile bin/rm
bin/rm/rm_test:unlink_dash_filename -> passed [0.088s]

Results file id is usr_tests.20180912-125312-617400
Results saved to /home/yuri/.kyua/store/results.usr_tests.20180912-125312-617400.db

1/1 passed (0 failed)

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision is now accepted and ready to land.Sep 12 2018, 1:19 PM
0mp added a subscriber: 0mp.

The manpage update looks fine.

This revision was automatically updated to reflect the committed changes.