There's a report about a nightly "crash" when users download, compile
from source, and replace their distro's mindlnad binary. This is because
the Debian package includes a patch that uses SIGUSR2 to reopen the log
file and sends SIGUSR2 from logrotate instead of just using the
"copytruncate" logrotate option. Then logrotate sends SIGUSR2 at 6:25AM,
which causes us to abort due to the unhandled signal.
I don't want to sacrifice SIGUSR2 just for log rotation, especially when
we already do some reload operations on SIGHUP. So to avoid this
Debian/Ubuntu issue, we'll explicitly ignore SIGUSR2, and add log file
reopening to the SIGHUP handler. Then hopefully a future Debian package
version will remove the SIGUSR2 patch and use SIGHUP instead (or
copytruncate).
Fixes: SF Bug #313 (log rotation kills minidlna service)
Add the ability to force title modification for clients that do their own
alphanumeric sorting. Adding a '!' to the beginning of the
force_sort_criteria value will enable this behavior.
It is implemented by prepending all titles with a zero-padded number, and
possibly season and episode (or disc and track) numbers if they aren't
already in the title.
Fix several issues with the non-destructive rescan functionality.
Most of these issues also affected inotify scanning as well. These
include annoying debug messages, adding album art for files that we
aren't supposed to be scanning anyway, incrementing the UpdateID when no
changes were made to the database, and other smaller issues.
Add support for upnp:playbackCount and upnp:lastPlaybackPosition tags.
These are used by Kodi to keep track of bookmark information as well as
determining whether to show the checkmark to indicate that the video
has been played.
Also add support for the UpdateObject command, which Kodi uses to
update the playbackCount and lastPlaybackPosition information.
This change requires a DB schema update, which should be done
automatically on the first run.
Inspired by SF user Karsten's patch #167.
By default, if there are multiple media directories specified, there
will be entries for each one in the root directory container. If
there is only one media directory specified, then just its contents
will be in the root container, to save one level of browsing.
Setting this option changes the default behavior so that multiple
media dirs will behave like a single media dir.
If an interface comes online after startup, we really need to send a
complete byebye + alive set on that interface, but we don't want to do
it for other interfaces. So do it as the interfaces come up, and
skip it for interfaces that existed before the reload.