Commit Graph

11877 Commits

Author SHA1 Message Date
Max Kellermann 414f00d6ae Makefile.am: add variable ANDROID_SDK_PLATFORM 2018-01-04 18:47:52 +01:00
Max Kellermann 17b0add058 filter/Observer: pass Reset() to underlying Filter
Wohooooo, the method Filter::Reset() has been broken because no
implementation of it has ever been called for a loooong time.
And nobody ever noticed it.  WTF.
2018-01-02 22:13:14 +01:00
Max Kellermann c68ed40661 pcm/SoxrResampler: implement method Reset() 2018-01-02 21:53:09 +01:00
Max Kellermann ff624075a8 storage/State: check if a CompositeStorage exists; fixes nullptr dereference
Fixes another crash bug caused by commit
64d141f71e
2018-01-02 14:13:26 +01:00
Max Kellermann 08db28469d storage/State: make mount errors non-fatal
Fixes crash bug caused by commit
64d141f71e
2018-01-02 14:07:52 +01:00
Max Kellermann a20b326807 storage/State: fix memory leak after database mount failure
Caused by commit 64d141f71e

This wasn't a serious memory leak, because after a mount failure, MPD
would abort anyway, which is subject to the next commit.
2018-01-02 14:05:07 +01:00
Max Kellermann 4db1b1b250 storage/State: remove useless #ifdef ENABLE_DATABASE
This source file isn't compiled when the database is disabled.
2018-01-02 13:48:16 +01:00
Max Kellermann ff6b263b48 increment version number to 0.20.15 2018-01-02 13:46:03 +01:00
Max Kellermann c0bf052fa9 release v0.20.14 2018-01-01 17:55:38 +01:00
loujine 5419cff925 [doc] Fix outdated MusicBrainz URLs (closes #179) 2018-01-01 17:30:24 +01:00
Max Kellermann eee10ad2ed input/curl: add missing mutex locks to OnEnd(), OnError() 2017-12-26 20:01:13 +01:00
Max Kellermann 98472a8104 pcm/SampleFormat: remove wrong "malloc" attribute 2017-12-23 08:38:22 +01:00
Max Kellermann d094c168aa archive/{iso9660,zzip}: unlock the mutex during I/O
Similar to commit 31ab78ae8e
2017-12-22 16:09:03 +01:00
Max Kellermann 4b18460bc6 archive/bz2: unlock the archive mutex and lock the file mutex
Fixes deadlock because FileInputStream::Read() unlocks the mutex
(which was not locked) and then locks it, keeping it locked.  This can
result in a deadlock.  This happens because the archive and the file
mutex are different.
2017-12-22 16:02:23 +01:00
Max Kellermann 412c0a965c util/WStringAPI: fix indent 2017-12-21 18:45:26 +01:00
Ilya ilyxa Tyshchenko 2becf79223 correct action for compile on Solaris 11.3 X86 2017-12-21 18:42:36 +01:00
Max Kellermann 43ec96d4a0 command/Error: translate std::{length_error,out_of_range} to ACK_ERROR_ARG 2017-12-21 10:22:04 +01:00
Max Kellermann 3d1d779da7 storage/State: use std::set instead of sorting a std::list 2017-12-21 10:22:00 +01:00
Max Kellermann c88056ba83 db/simple: fix file corruption in the presence of mount points
If a directory is a mount point, omit the "directory: " as well.

This bug is years old, but has become more visible now that mount
points are persistent in the state file.
2017-12-21 10:16:52 +01:00
Max Kellermann e769751221 increment version number to 0.20.14 2017-12-21 10:15:16 +01:00
Max Kellermann 49b9a90c3f release v0.20.13 2017-12-18 23:41:56 +01:00
FlashSystems 64d141f71e Save and restore mountpoints within the state file.
Signed-off-by: FlashSystems <developer@flashsystems.de>
2017-12-18 23:39:01 +01:00
FlashSystems c488d3123f Fix `lsinfo` and `add` for mounted databases.
If `SimpleDatabase::Visit` is called on a database that contains a mounted directry the URIs of the elements passed to the callbacks are not prefixed by the mountpoint path. This leads to lsinfo and add not working because they use the wrong URI. This pull request is using the `WalkMount` helper function to create prefixed versions of `VisitDirectory`, `VisitSong` and `VisitPlaylist` to add the correct prefix to the parameters of the callback functions.
2017-12-18 23:33:08 +01:00
Stefano Miccoli 967af60327 rounds alsa HW mixer volume towards ±∞ depending on sgn(∆ vol)
This alleviates a problem in which 'volume +1' cannot be undo by
'volume -1' when using alsa hw mixer.

Closes #104
2017-12-18 21:29:03 +01:00
Yue Wang f1ef9f9d31 OSXOutputPlugin: set the buffer time to be 100ms
[mk: the following text was copied from
https://github.com/MusicPlayerDaemon/MPD/pull/167]

For certain format (hi-res files) and normal buffer size hardware, The
hardware may at once consume most of the buffers. However, in Delay()
function, MPD is supposed to wait for 25 ms after the next try. it
will create a hiccup. The negative impact is much major than
increasing the latency.

I understand larger buffers come at a price. That's why in my earlier
commit last year I significantly reduced it. However, the buffer size
in CoreAudio is set according to the hardware, which is super small
latency. For instance, the system audio of 2015 generation of macbook
pro has maximum buffer size of 4096 samples, which is just 0.09s for
44.1k framerate, or 0.04s for 96k frames --- . compare to the 0.5 sec
latency alsa plugin has, even if we quadruple it, it's still super
tiny.
2017-12-12 10:56:42 +01:00
Max Kellermann dfaf08743c *: check defined(_WIN32) instead of defined(WIN32)
Only _WIN32 is defined by the compiler, and WIN32 is not standardized
and may be missing.

Closes #169
2017-12-12 10:22:20 +01:00
Max Kellermann d9552d8a6d android/build.py: support NDK r16 2017-12-12 10:01:47 +01:00
Max Kellermann 7586a8ab2c python/build/libs.py: disable the FFmpeg HEVC decoder due to clang build failure 2017-12-12 10:01:47 +01:00
Max Kellermann e1a942250b python/build/libs.py: disable more FFmpeg features 2017-12-12 09:57:40 +01:00
Max Kellermann 72be0185de python/libs: upgrade Boost to 1.65.1 2017-12-12 09:16:40 +01:00
Max Kellermann 7e4cbce06b python/build/libs: upgrade CURL to 7.57.0 2017-12-12 09:15:24 +01:00
Max Kellermann 177d62f431 python/build/libs: upgrade FFmpeg to 3.4.1 2017-12-11 19:00:22 +01:00
Uwe Kleine-König 5a11e03725 lib/upnp: use include path without upnp/ prefix and honor pkg-config CFLAGS
If libupnp is installed in a non-standard location we must rely on the
include path provided by $(pkg-config --cflags libupnp). Relative to the
path given from that command no prefix must be used to find the respective
files.
2017-12-11 18:58:09 +01:00
Max Kellermann 75d068b7cd Makefile.am: include Windows cross-build script in source tarball 2017-12-05 11:24:52 +01:00
FlashSystems 1208503888 Removing gcc_malloc attribute from `Directory::CreateChild` to fix
assignment of `mnt->mounted_database` in `SimpleDatabase::Mount`.
2017-12-03 12:34:08 +01:00
Max Kellermann de90d401d2 MusicChunk: add magic value IGNORE_REPLAY_GAIN
This fixes spurious replay gain logs when the player inserts silence
chunks, because those silence chunks had no replay gain attached,
resetting the ReplayGainFilter state, flipping it forth and back.
2017-12-03 11:39:12 +01:00
Max Kellermann 396defaea9 MusicChunk: initialize replay_gain_serial on demand 2017-12-03 11:39:07 +01:00
Max Kellermann 18f350cd04 player/Thread: initialize MusicChunk::bit_rate in SendSilence()
This attribute is not particularly important, but it was
uninitialized.
2017-12-03 10:54:14 +01:00
Max Kellermann 478180ebe4 queue/PlaylistEdit: shuffle appended songs only within its priority group
Fixes #165.
2017-12-02 17:17:02 +01:00
Max Kellermann 4a3059f509 queue/PlaylistControl: don't skip highest priority song on "play"
When starting playback with a specific song which does not have the
highest priority, the previous highest priority song was skipped
completely because its order was "swapped".  This commit changes to a
more expensive operation which inserts the selected song into the
order list.

This fixes a small part of #165
2017-12-02 16:25:32 +01:00
Max Kellermann 78728138a0 lib/upnp/Compat: disable the 1.8 API emulation with libupnp 1.6.24
libupnp 1.6.24 added a few badly designed macros which break the MPD
build:

 8177a4195a/

To work around this, we disable our emulation functions (from
714011c81e) on this libupnp version.

Closes #163
2017-12-02 14:47:27 +01:00
FlashSystems 63fc98591d Fix for "Mount-Points are purged from database on update/rescan."
Signed-off-by: FlashSystems <developer@flashsystems.de>
2017-11-27 22:34:49 +01:00
Max Kellermann 53def9a682 increment version number to 0.20.13 2017-11-27 22:32:55 +01:00
Max Kellermann 323231d1dd release v0.20.12 2017-11-25 19:32:37 +01:00
Max Kellermann 714011c81e lib/upnp: adapt to libupnp 1.8 API changes
Closes #155
2017-11-16 11:39:11 +01:00
Max Kellermann 952ff4207b lib/upnp/Callback: make "evp" parameter const 2017-11-16 11:37:58 +01:00
Max Kellermann 150b16ec2c lib/upnp/Discovery: make Upnp_Discovery pointers const 2017-11-16 11:37:04 +01:00
Max Kellermann c98bc4a243 playlist/PlaylistRegistry: use LockRewind() instead of Rewind()
Fixes a deadlock caused by commit
31ab78ae8e.  That commit was not
actually bad - just these two calls have always been bad, which went
unnoticed for a long time.
2017-11-14 21:19:22 +01:00
Max Kellermann 014f8cd693 output/httpd: flush encoder after tag
Without the flush, ReadPage() may not return any data, or not all
data.  This may result in incomplete ddata the new "header" page,
corrupting streams with some encoders such as Vorbis.

Fixes #145
2017-11-14 12:00:14 +01:00
Max Kellermann aea37e46e3 encoder/vorbis: default to quality 3
Don't require a quality or bitrate setting.  If nothing is set, don't
fail startup - just go with a good default.  A quality setting of 3 is
what "oggenc" defaults to as well.
2017-11-14 11:30:28 +01:00