Stop all sesions when mpd frontend is asked to stop
This commit is contained in:
parent
75984dda6a
commit
a3d72351d9
@ -5,6 +5,7 @@ from pykka.actor import ThreadingActor
|
||||
|
||||
from mopidy import settings
|
||||
from mopidy.utils import network
|
||||
from mopidy.utils.process import stop_actors_by_class
|
||||
from mopidy.frontends.mpd.dispatcher import MpdDispatcher
|
||||
from mopidy.frontends.mpd.protocol import ENCODING, VERSION, LINE_TERMINATOR
|
||||
|
||||
@ -40,6 +41,9 @@ class MpdFrontend(ThreadingActor):
|
||||
def on_receive(self, message):
|
||||
pass # Ignore state info that is sent to frontend.
|
||||
|
||||
def on_stop(self):
|
||||
stop_actors_by_class(MpdSession)
|
||||
|
||||
|
||||
class MpdSession(network.LineProtocol):
|
||||
"""
|
||||
|
||||
Loading…
Reference in New Issue
Block a user