diff --git a/multimedia/mediatomb/Makefile b/multimedia/mediatomb/Makefile index ebd4c8dfce4..a3b527e6938 100644 --- a/multimedia/mediatomb/Makefile +++ b/multimedia/mediatomb/Makefile @@ -1,10 +1,10 @@ -# $OpenBSD: Makefile,v 1.23 2017/04/10 11:46:23 sthen Exp $ +# $OpenBSD: Makefile,v 1.24 2017/05/19 13:19:59 espie Exp $ COMMENT = UPnP media server VER = 0.12.1 DISTNAME = mediatomb-${VER} -REVISION = 14 +REVISION = 15 CATEGORIES = multimedia diff --git a/multimedia/mediatomb/patches/patch-src_hash_dbo_hash_h b/multimedia/mediatomb/patches/patch-src_hash_dbo_hash_h new file mode 100644 index 00000000000..eb9da7b833c --- /dev/null +++ b/multimedia/mediatomb/patches/patch-src_hash_dbo_hash_h @@ -0,0 +1,42 @@ +$OpenBSD: patch-src_hash_dbo_hash_h,v 1.1 2017/05/19 13:19:59 espie Exp $ +two phase name lookup + +Index: src/hash/dbo_hash.h +--- src/hash/dbo_hash.h.orig ++++ src/hash/dbo_hash.h +@@ -106,7 +106,7 @@ class DBOHash : public DHashBase *slot; +- if (! search(key, &slot)) ++ if (! this->search(key, &slot)) + return false; + slot->key = deletedKey; + slot->value->release(); +@@ -136,7 +136,7 @@ class DBOHash : public DHashBase value) + { + struct dbo_hash_slot *slot; +- search(key, &slot); ++ this->search(key, &slot); + put(key, (hash_slot_t)slot, value); + } + void put(KT key, hash_slot_t destSlot, zmm::Ref value) +@@ -162,7 +162,7 @@ class DBOHash : public DHashBase get(KT key) + { + struct dbo_hash_slot *slot; +- bool found = search(key, &slot); ++ bool found = this->search(key, &slot); + if (found) + return zmm::Ref(slot->value); + else +@@ -174,7 +174,7 @@ class DBOHash : public DHashBase get(KT key, hash_slot_t *destSlot) + { + struct dbo_hash_slot **slot = (struct dbo_hash_slot **)destSlot; +- bool found = search(key, slot); ++ bool found = this->search(key, slot); + if (found) + return zmm::Ref((*slot)->value); + else diff --git a/multimedia/mediatomb/patches/patch-src_hash_dbr_hash_h b/multimedia/mediatomb/patches/patch-src_hash_dbr_hash_h new file mode 100644 index 00000000000..0db350be85f --- /dev/null +++ b/multimedia/mediatomb/patches/patch-src_hash_dbr_hash_h @@ -0,0 +1,33 @@ +$OpenBSD: patch-src_hash_dbr_hash_h,v 1.1 2017/05/19 13:19:59 espie Exp $ +two phase name lookup + +Index: src/hash/dbr_hash.h +--- src/hash/dbr_hash.h.orig ++++ src/hash/dbr_hash.h +@@ -124,7 +124,7 @@ class DBRHash : public DHashBase *slot; +- if (! search(key, &slot)) ++ if (! this->search(key, &slot)) + return false; + slot->key = deletedKey; + int array_slot = slot->array_slot; +@@ -134,7 +134,7 @@ class DBRHash : public DHashBasecount]; +- if (! search(data_array[array_slot], &slot)) ++ if (! this->search(data_array[array_slot], &slot)) + { + log_debug("DBR-Hash-Error: (%d; array_slot=%d; count=%d)\n", data_array[array_slot], array_slot, this->count); + throw zmm::Exception(_("DBR-Hash-Error: key in data_array not found in hashtable")); +@@ -146,7 +146,7 @@ class DBRHash : public DHashBase *slot; +- if (! search(key, &slot)) ++ if (! this->search(key, &slot)) + { + #ifdef TOMBDEBUG + if (this->count >= realCapacity) diff --git a/multimedia/mediatomb/patches/patch-src_hash_dso_hash_h b/multimedia/mediatomb/patches/patch-src_hash_dso_hash_h new file mode 100644 index 00000000000..3d036579333 --- /dev/null +++ b/multimedia/mediatomb/patches/patch-src_hash_dso_hash_h @@ -0,0 +1,42 @@ +$OpenBSD: patch-src_hash_dso_hash_h,v 1.1 2017/05/19 13:19:59 espie Exp $ +two phase name lookup + +Index: src/hash/dso_hash.h +--- src/hash/dso_hash.h.orig ++++ src/hash/dso_hash.h +@@ -100,7 +100,7 @@ class DSOHash : public DHashBase *slot; +- if (! search(key, &slot)) ++ if (! this->search(key, &slot)) + return false; + slot->key->release(); + slot->value->release(); +@@ -112,7 +112,7 @@ class DSOHash : public DHashBase value) + { + struct dso_hash_slot *slot; +- search(key, &slot); ++ this->search(key, &slot); + put(key, (hash_slot_t)slot, value); + } + void put(zmm::String key, hash_slot_t destSlot, zmm::Ref value) +@@ -141,7 +141,7 @@ class DSOHash : public DHashBase get(zmm::String key) + { + struct dso_hash_slot *slot; +- bool found = search(key, &slot); ++ bool found = this->search(key, &slot); + if (found) + return zmm::Ref(slot->value); + else +@@ -153,7 +153,7 @@ class DSOHash : public DHashBase get(zmm::String key, hash_slot_t *destSlot) + { + struct dso_hash_slot **slot = (struct dso_hash_slot **)destSlot; +- bool found = search(key, slot); ++ bool found = this->search(key, slot); + if (found) + return zmm::Ref((*slot)->value); + else diff --git a/multimedia/mediatomb/patches/patch-src_singleton_h b/multimedia/mediatomb/patches/patch-src_singleton_h new file mode 100644 index 00000000000..d2c62848d20 --- /dev/null +++ b/multimedia/mediatomb/patches/patch-src_singleton_h @@ -0,0 +1,23 @@ +$OpenBSD: patch-src_singleton_h,v 1.1 2017/05/19 13:19:59 espie Exp $ +pre-declare, not enough to shup up all warnings + +Index: src/singleton.h +--- src/singleton.h.orig ++++ src/singleton.h +@@ -58,6 +58,8 @@ class SingletonManager : public zmm::Object (protected + template + class Singleton : public zmm::Object + { ++protected: ++ static zmm::Ref mutex; + public: + static zmm::Ref getInstance() + { +@@ -87,7 +89,6 @@ class Singleton : public zmm::Object (protected) + virtual void init() { } + virtual void shutdown() { } + +- static zmm::Ref mutex; + static zmm::Ref instance; + static bool singletonActive; + diff --git a/multimedia/mediatomb/patches/patch-tombupnp_upnp_src_genlib_net_http_webserver_c b/multimedia/mediatomb/patches/patch-tombupnp_upnp_src_genlib_net_http_webserver_c new file mode 100644 index 00000000000..7f41767eceb --- /dev/null +++ b/multimedia/mediatomb/patches/patch-tombupnp_upnp_src_genlib_net_http_webserver_c @@ -0,0 +1,15 @@ +$OpenBSD: patch-tombupnp_upnp_src_genlib_net_http_webserver_c,v 1.1 2017/05/19 13:19:59 espie Exp $ +gnu89 inlines + +Index: tombupnp/upnp/src/genlib/net/http/webserver.c +--- tombupnp/upnp/src/genlib/net/http/webserver.c.orig ++++ tombupnp/upnp/src/genlib/net/http/webserver.c +@@ -310,7 +310,7 @@ search_extension( IN const char *extension, + * 0 - On Sucess + * UPNP_E_OUTOF_MEMORY - on memory allocation failures + ************************************************************************/ +-XINLINE int ++int + get_content_type( IN const char *filename, + OUT DOMString * content_type ) + { diff --git a/multimedia/mediatomb/patches/patch-tombupnp_upnp_src_uuid_upnp_md5_c b/multimedia/mediatomb/patches/patch-tombupnp_upnp_src_uuid_upnp_md5_c new file mode 100644 index 00000000000..7cbba480599 --- /dev/null +++ b/multimedia/mediatomb/patches/patch-tombupnp_upnp_src_uuid_upnp_md5_c @@ -0,0 +1,15 @@ +$OpenBSD: patch-tombupnp_upnp_src_uuid_upnp_md5_c,v 1.1 2017/05/19 13:19:59 espie Exp $ +XXX real size bug! + +Index: tombupnp/upnp/src/uuid/upnp_md5.c +--- tombupnp/upnp/src/uuid/upnp_md5.c.orig ++++ tombupnp/upnp/src/uuid/upnp_md5.c +@@ -137,7 +137,7 @@ MD5Final(md5byte digest[16], struct MD5Context *ctx) + + byteSwap(ctx->buf, 4); + memcpy(digest, ctx->buf, 16); +- memset(ctx, 0, sizeof(ctx)); /* In case it's sensitive */ ++ memset(ctx, 0, sizeof(*ctx)); /* In case it's sensitive */ + } + + #ifndef ASM_MD5