forked from pool/bluez
Accepting request 664446 from home:seife:testing
add bluez-5.50-gcc9.patch (boo#1121404, bko#202213) OBS-URL: https://build.opensuse.org/request/show/664446 OBS-URL: https://build.opensuse.org/package/show/Base:System/bluez?expand=0&rev=255
This commit is contained in:
parent
cea9570806
commit
d25b5894c8
49
bluez-5.50-gcc9.patch
Normal file
49
bluez-5.50-gcc9.patch
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
Index: b/unit/test-sdp.c
|
||||||
|
===================================================================
|
||||||
|
--- a/unit/test-sdp.c
|
||||||
|
+++ b/unit/test-sdp.c
|
||||||
|
@@ -29,6 +29,7 @@
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <stdbool.h>
|
||||||
|
#include <sys/socket.h>
|
||||||
|
+#include <sys/uio.h>
|
||||||
|
|
||||||
|
#include <glib.h>
|
||||||
|
|
||||||
|
@@ -197,27 +198,23 @@ static gboolean send_pdu(gpointer user_d
|
||||||
|
{
|
||||||
|
struct context *context = user_data;
|
||||||
|
const struct sdp_pdu *req_pdu;
|
||||||
|
- uint16_t pdu_len;
|
||||||
|
- unsigned char *buf;
|
||||||
|
+ struct iovec iov[2];
|
||||||
|
ssize_t len;
|
||||||
|
|
||||||
|
req_pdu = &context->data->pdu_list[context->pdu_offset];
|
||||||
|
|
||||||
|
- pdu_len = req_pdu->raw_size + context->cont_size;
|
||||||
|
+ iov[0].iov_base = (void *) req_pdu->raw_data;
|
||||||
|
+ iov[0].iov_len = req_pdu->raw_size;
|
||||||
|
|
||||||
|
- buf = g_malloc0(pdu_len);
|
||||||
|
+ iov[1].iov_base = context->cont_data;
|
||||||
|
+ iov[1].iov_len = context->cont_size;
|
||||||
|
|
||||||
|
- memcpy(buf, req_pdu->raw_data, req_pdu->raw_size);
|
||||||
|
+ if (context->cont_size && context->cont_size != req_pdu->cont_len)
|
||||||
|
+ put_be16(req_pdu->cont_len, iov[1].iov_base + 4);
|
||||||
|
|
||||||
|
- if (context->cont_size > 0)
|
||||||
|
- memcpy(buf + req_pdu->raw_size, context->cont_data,
|
||||||
|
- context->cont_size);
|
||||||
|
+ len = writev(context->fd, iov, 2);
|
||||||
|
|
||||||
|
- len = write(context->fd, buf, pdu_len);
|
||||||
|
-
|
||||||
|
- g_free(buf);
|
||||||
|
-
|
||||||
|
- g_assert(len == pdu_len);
|
||||||
|
+ g_assert(len == (ssize_t) (iov[0].iov_len + iov[1].iov_len));
|
||||||
|
|
||||||
|
return FALSE;
|
||||||
|
}
|
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Jan 10 18:55:13 UTC 2019 - Stefan Seyfried <seife+obs@b1-systems.com>
|
||||||
|
|
||||||
|
- add bluez-5.50-gcc9.patch (boo#1121404, bko#202213)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Jun 4 19:15:59 UTC 2018 - seife+obs@b1-systems.com
|
Mon Jun 4 19:15:59 UTC 2018 - seife+obs@b1-systems.com
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package bluez
|
# spec file for package bluez
|
||||||
#
|
#
|
||||||
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||||
# Copyright (c) 2010-2017 B1 Systems GmbH, Vohburg, Germany
|
# Copyright (c) 2010-2017 B1 Systems GmbH, Vohburg, Germany
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
@ -13,7 +13,7 @@
|
|||||||
# license that conforms to the Open Source Definition (Version 1.9)
|
# license that conforms to the Open Source Definition (Version 1.9)
|
||||||
# published by the Open Source Initiative.
|
# published by the Open Source Initiative.
|
||||||
|
|
||||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
@ -38,6 +38,8 @@ Patch4: bluez-5.45-disable-broken-tests.diff
|
|||||||
Patch5: 0001-obexd-use-AM_LDFLAGS-for-linking.patch
|
Patch5: 0001-obexd-use-AM_LDFLAGS-for-linking.patch
|
||||||
# disable tests for bypass boo#1078285
|
# disable tests for bypass boo#1078285
|
||||||
Patch6: disable_some_obex_tests.patch
|
Patch6: disable_some_obex_tests.patch
|
||||||
|
# gcc9
|
||||||
|
Patch7: bluez-5.50-gcc9.patch
|
||||||
# Upstream suggests to use btmon instead of hcidump and does not want those patches
|
# Upstream suggests to use btmon instead of hcidump and does not want those patches
|
||||||
# => PATCH-FIX-OPENSUSE for those two :-)
|
# => PATCH-FIX-OPENSUSE for those two :-)
|
||||||
# fix some memory leak with malformed packet (reported upstream but not yet fixed)
|
# fix some memory leak with malformed packet (reported upstream but not yet fixed)
|
||||||
@ -151,6 +153,7 @@ desktop specific applets like blueman or GNOME or KDE applets).
|
|||||||
%ifarch ppc ppc64 ppc64le
|
%ifarch ppc ppc64 ppc64le
|
||||||
%patch6 -p1
|
%patch6 -p1
|
||||||
%endif
|
%endif
|
||||||
|
%patch7 -p1
|
||||||
%patch101 -p1
|
%patch101 -p1
|
||||||
%patch102 -p1
|
%patch102 -p1
|
||||||
mkdir dbus-apis
|
mkdir dbus-apis
|
||||||
|
Loading…
Reference in New Issue
Block a user