Merge branch 'v0.23.x'
This commit is contained in:
commit
8a7b7dffec
4
NEWS
4
NEWS
|
@ -27,6 +27,10 @@ ver 0.24 (not yet released)
|
|||
* remove Haiku support
|
||||
* require libfmt 7 or later
|
||||
|
||||
ver 0.23.12 (not yet released)
|
||||
* tags
|
||||
- fix crash bug due to race condition
|
||||
|
||||
ver 0.23.11 (2022/11/28)
|
||||
* database
|
||||
- simple: move default database to ~/.cache/mpd/db from ~/.cache/mpd.db
|
||||
|
|
|
@ -2,8 +2,8 @@
|
|||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="org.musicpd"
|
||||
android:installLocation="auto"
|
||||
android:versionCode="70"
|
||||
android:versionName="0.23.11">
|
||||
android:versionCode="71"
|
||||
android:versionName="0.23.12">
|
||||
|
||||
<uses-sdk android:minSdkVersion="21" android:targetSdkVersion="30"/>
|
||||
|
||||
|
|
|
@ -27,7 +27,11 @@
|
|||
#include "util/IntrusiveList.hxx"
|
||||
#include "util/IntrusiveHashSet.hxx"
|
||||
|
||||
#include <array>
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
#include <string>
|
||||
#include <utility>
|
||||
|
||||
class RemoteTagCacheHandler;
|
||||
|
||||
|
|
|
@ -42,6 +42,8 @@
|
|||
#include "io/UniqueFileDescriptor.hxx"
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
class Path;
|
||||
class FileInfo;
|
||||
|
||||
|
|
|
@ -187,10 +187,6 @@ public:
|
|||
SetOption(CURLOPT_POSTFIELDSIZE, (long)size);
|
||||
}
|
||||
|
||||
void SetHttpPost(const struct curl_httppost *post) {
|
||||
SetOption(CURLOPT_HTTPPOST, post);
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
bool GetInfo(CURLINFO info, T value_r) const noexcept {
|
||||
return ::curl_easy_getinfo(handle, info, value_r) == CURLE_OK;
|
||||
|
@ -200,10 +196,10 @@ public:
|
|||
* Returns the response body's size, or -1 if that is unknown.
|
||||
*/
|
||||
[[gnu::pure]]
|
||||
int64_t GetContentLength() const noexcept {
|
||||
double value;
|
||||
return GetInfo(CURLINFO_CONTENT_LENGTH_DOWNLOAD, &value)
|
||||
? (int64_t)value
|
||||
curl_off_t GetContentLength() const noexcept {
|
||||
curl_off_t value;
|
||||
return GetInfo(CURLINFO_CONTENT_LENGTH_DOWNLOAD_T, &value)
|
||||
? value
|
||||
: -1;
|
||||
}
|
||||
|
||||
|
|
|
@ -261,8 +261,14 @@ TagBuilder::RemoveAll() noexcept
|
|||
void
|
||||
TagBuilder::RemoveType(TagType type) noexcept
|
||||
{
|
||||
if (items.empty())
|
||||
/* don't acquire the tag_pool_lock if we're not going
|
||||
to call tag_pool_put_item() anyway */
|
||||
return;
|
||||
|
||||
const auto begin = items.begin(), end = items.end();
|
||||
|
||||
const std::scoped_lock<Mutex> protect(tag_pool_lock);
|
||||
items.erase(std::remove_if(begin, end,
|
||||
[type](TagItem *item) {
|
||||
if (item->type != type)
|
||||
|
|
Loading…
Reference in New Issue