Small bug fix on the dependency handlers

service_changed() might be called event after stop() and clear().
Now, service events are ignored once clear() has been called.