Bug 239560 - sysrc misinterprets "variable=value"-like strings as real assignments
Summary: sysrc misinterprets "variable=value"-like strings as real assignments
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-bugs (Nobody)
Depends on:
Reported: 2019-07-31 15:05 UTC by Mateusz Piotrowski
Modified: 2020-12-11 17:02 UTC (History)
2 users (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Mateusz Piotrowski freebsd_committer 2019-07-31 15:05:11 UTC
Here is a file that can be used to reproduce the bug:


Now the result of running `sysrc -f file -a` is:

> real:
> fake=0
> fake:

The bug is that sysrc should not print "fake:" here.

I'm running FreeBSD 13.0-CURRENT r350403.
Comment 1 Devin Teske freebsd_committer 2020-12-11 17:02:56 UTC
Thanks for the report, I'll have a go at fixing it to produce the expected results