NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

standards/50647: "echo -n" in rc.subr breaks the stop command on OSX



>Number:         50647
>Category:       standards
>Synopsis:       "echo -n" in rc.subr breaks the stop command on OSX
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    standards-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jan 11 15:30:00 +0000 2016
>Originator:     Emile `iMil' Heitor
>Release:        Mac OSX 10.10
>Organization:
NetBSD
>Environment:
Darwin kressh.home.imil.net 14.5.0 Darwin Kernel Version 14.5.0: Tue Sep  1 21:23:09 PDT 2015; root:xnu-2782.50.1~1/RELEASE_X86_64 x86_64
>Description:
rc.subr uses `echo -n` in various functions, this makes the script not portable under operating systems not supporting echo "-n" flag.
>How-To-Repeat:
Use rc.subr on Mac OSX, try a rc.d script and witness:

/etc/rc.subr: line 706: kill: 29370: invalid signal specification
>Fix:
Simply replace "echo -n" with "printf".



Home | Main Index | Thread Index | Old Index