Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

return id for "addid" with position #8

Merged
merged 1 commit into from
Jun 13, 2016

Conversation

ewollesen
Copy link
Contributor

Previously the id was being returned only when a position wasn't
specified.

Previously the id was being returned only when a position wasn't
specified.
@MaxKellermann MaxKellermann merged commit 81a198a into MusicPlayerDaemon:master Jun 13, 2016
@skidoo23 skidoo23 mentioned this pull request Aug 12, 2021
lotheac added a commit to lotheac/MPD that referenced this pull request Dec 4, 2024
this fixes listening on the XDG runtime dir socket if binding to the
configured tcp port fails.

while listen_global_init() does in fact start listening on the XDG
runtime dir socket, a failure to listen to the configured port causes
all listener fd's, including the perfectly valid unix socket, to be
closed:

	(gdb) bt
	#0  close (fd=10) at src/unistd/close.c:15
	MusicPlayerDaemon#1  0x00005555555b2db7 in FileDescriptor::Close (this=0x7fffec777f80)
	    at ../src/io/FileDescriptor.hxx:201
	MusicPlayerDaemon#2  0x0000555555635a51 in SocketEvent::Close (this=0x7fffec777f58) at ../src/event/SocketEvent.cxx:46
	MusicPlayerDaemon#3  0x00005555556385a0 in ServerSocket::OneServerSocket::Close (this=0x7fffec777f50)
	    at ../src/event/ServerSocket.cxx:83
	MusicPlayerDaemon#4  0x0000555555637777 in ServerSocket::Close (this=0x7fffef911f90)
	    at ../src/event/ServerSocket.cxx:270
	MusicPlayerDaemon#5  0x00005555556374d5 in ServerSocket::Open (this=0x7fffef911f90)
	    at ../src/event/ServerSocket.cxx:260
	MusicPlayerDaemon#6  0x00005555555bb0a4 in listen_global_init (config=..., listener=...) at ../src/Listen.cxx:139
	MusicPlayerDaemon#7  0x0000555555583c9b in MainConfigured (options=..., raw_config=...) at ../src/Main.cxx:355
	MusicPlayerDaemon#8  0x000055555558467e in MainOrThrow (argc=3, argv=0x7fffffffe738) at ../src/Main.cxx:663
	MusicPlayerDaemon#9  0x00005555555846fa in mpd_main (argc=3, argv=0x7fffffffe738) at ../src/Main.cxx:669
	MusicPlayerDaemon#10 0x000055555558475d in main (argc=3, argv=0x7fffffffe738) at ../src/Main.cxx:681

to fix that, consider listeners added by AddFD "good" so that it is kept
open even if the tcp listens fail.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants