/lib/init/init-d-script: exit 0 at end of script prevents all other exit codes

Dmitry Bogatov KAction at debian.org
Sun Nov 11 21:08:37 GMT 2018

[2016-04-26 23:41] J Mo <jmomo at jmomo.net>
> Package: sysvinit-utils
> Version: 2.88dsf-59.3
> Severity: important
> The last line of /lib/init/init-d-script is "exit 0".

> That can't be right, can it? This overrides all other valid return
> codes which could be provid ed by the script. In almost all cases,
> even errors, $? is going to be 0.

I do agree, that this line looks strange. It was introduced at commit
`f611a05d16b3094139c2ea540817c00bdf93347a' with following comment:

	Make sure init-d-script exit at the end, to make sure init.d
	script is only sourced once.

at 20 Feb 2014. Dear co-maintainers, do you understand (or remember),
what is going on?

More information about the Debian-init-diversity mailing list