[mpd-devel] [Patch] Database proxy plugin: retry connection attempts at startup

2014-11-30 Thread Piotr Kozłowski
Hi, I've written a patch that allows configurable number of attempts to connect to remote MPD server if there are any errors. I'm running MPD proxy on a headless single board computer. It often happens that the first connection attempt fails, usually because of the delays in configuring the

Re: [mpd-devel] [Patch] Database proxy plugin: retry connection attempts at startup

2014-11-30 Thread Max Kellermann
On 2014/11/30 19:52, Piotr Koz??owski pi...@pkozlowski.pl wrote: Hi, I've written a patch that allows configurable number of attempts to connect to remote MPD server if there are any errors. I'm running MPD proxy on a headless single board computer. It often happens that the first

Re: [mpd-devel] [Patch] Database proxy plugin: retry connection attempts at startup

2014-11-30 Thread Max Kellermann
On 2014/11/30 20:20, Piotr Koz??owski pi...@pkozlowski.pl wrote: Use of sleep() is unacceptable. Could you explain why? I've seen usage of usleep() in other parts of the code - would it be better here? Otherwise what do you suggest? I'm new to MPD development, so any advice is welcome. All