init script for afpd daemon from netatalk-2.2.1 (and other versions) "needs" avahi daemon unconditionally (if compiled with USE='avahi'). At the same time
avahi may not be needed if parameter '-nozeroconf' is passed. Init script should check on the presence of this parameter, similarly as it checks on -dpp for need for atalkd.
Steps to Reproduce:
1. configure -nozeroconf in /etc/netatalk/afpd.conf
2. "/etc/init.d/afpd start" still starts avahi-daemon as well
3. worse "/etc/init.d/avahi-daemon stop" stops also afpd
easy fix is to replace
by something like
sed -e 's:#.*::' /etc/netatalk/afpd.conf | fgrep -q -e -nozeroconf \
|| need avahi-daemon
(I missed this one because I wasn't in CC.)
Okay this is something I should address, but unfortunately it's not as easy as you wrote, as you might have only one server with -nozeroconf — it's much easier with -ddp as that's a "positive" action.
I'll try to get this in on -r4.