git: rc.d/sysctl: Rewrite to be more robust and clean
Sepherosa Ziehau
sepherosa at gmail.com
Fri Feb 1 05:33:18 PST 2019
Please check fix this commit, there are several unexpected effects of
this commit:
- Extra original value printed on the screen, when this script is run.
Before this change, a=`cmd` will not print anything on the screen.
- It looks after or during "TCP options" sysctl, this script is
invoked again in a quite verbose mode, which does not happen before.
Thanks,
sephe
On Thu, Dec 20, 2018 at 10:28 AM Aaron LI <aly at crater.dragonflybsd.org> wrote:
>
>
> commit 87206e7c403a8c39917ab3389bb5c3259b68b501
> Author: Aaron LI <aly at aaronly.me>
> Date: Thu Dec 13 13:58:27 2018 +0800
>
> rc.d/sysctl: Rewrite to be more robust and clean
>
> * Check the validity of the sysctl config and warn about the invalid
> syntax.
>
> A common mistake is that users set 'sysctl <mib>=<val>' in
> /etc/sysctl.conf, which generate huge amount of junk/mysterious
> messages on the console. Now this will be warned.
>
> * Reorganize the logic to be much cleaner.
>
> * Do not bother to check whether the new value is different from the old
> one.
>
> * Rename the function for consistency.
>
> Summary of changes:
> etc/rc.d/sysctl | 65 +++++++++++++++++++++++++++++----------------------------
> 1 file changed, 33 insertions(+), 32 deletions(-)
>
> http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/87206e7c403a8c39917ab3389bb5c3259b68b501
>
>
> --
> DragonFly BSD source repository
--
Tomorrow Will Never Die
More information about the Commits
mailing list