OSDN Git Service

android-x86/external-bluetooth-bluez.git
11 years agocore: Handle existing start discovery gracefully
Marcel Holtmann [Sun, 20 Jan 2013 03:13:49 +0000 (19:13 -0800)]
core: Handle existing start discovery gracefully

In case a discovery already exists, keep using it if is has the same
type and only if not, stop it and start a new one.

11 years agocore: Simplify discovery start and stop handling
Marcel Holtmann [Sun, 20 Jan 2013 02:41:08 +0000 (18:41 -0800)]
core: Simplify discovery start and stop handling

To make the discovery start, stop and restart logic even simple, just
trigger start of discovery when client gets registered. It is almost
impossible to handle all corner cases, so just trigger another restart
of the discovery with a larger timeout in case of an error.

11 years agocore: Fix multiple issues with discovery handling
Marcel Holtmann [Sat, 19 Jan 2013 23:47:18 +0000 (15:47 -0800)]
core: Fix multiple issues with discovery handling

This patch is the first attempt in fixing the discovery issues for
dual-mode BR/EDR + LE controllers. It creates a clean chain for
start/stop discovery client handling and also for the internal
handling of suspend, resume and restart.

However this patch removes the LE connection handling. And that needs
to be put back with a separate patch.

11 years agotools: Use proper test data in mgmt_unblock_device test
Szymon Janc [Fri, 18 Jan 2013 19:28:12 +0000 (20:28 +0100)]
tools: Use proper test data in mgmt_unblock_device test

Copy and paste error. Although both data values are same use proper
one for clarity.

11 years agocore: Use discovery found list instead of nested struct
Marcel Holtmann [Sat, 19 Jan 2013 05:00:38 +0000 (21:00 -0800)]
core: Use discovery found list instead of nested struct

11 years agocore: Remove pending_mode session variable
Marcel Holtmann [Sat, 19 Jan 2013 04:49:58 +0000 (20:49 -0800)]
core: Remove pending_mode session variable

11 years agocore: Remove unneeded session reference counting
Marcel Holtmann [Sat, 19 Jan 2013 01:36:33 +0000 (17:36 -0800)]
core: Remove unneeded session reference counting

11 years agocore: Remove session_req_type variable and parameter
Marcel Holtmann [Sat, 19 Jan 2013 01:31:07 +0000 (17:31 -0800)]
core: Remove session_req_type variable and parameter

11 years agocore: Rename a few functions and parameters
Marcel Holtmann [Sat, 19 Jan 2013 01:27:58 +0000 (17:27 -0800)]
core: Rename a few functions and parameters

11 years agocore: Remove unused got_reply session variable
Marcel Holtmann [Sat, 19 Jan 2013 01:21:57 +0000 (17:21 -0800)]
core: Remove unused got_reply session variable

11 years agoAVRCP: Fix rejecting RegisterNotification if no transport exists
Luiz Augusto von Dentz [Thu, 17 Jan 2013 12:39:44 +0000 (14:39 +0200)]
AVRCP: Fix rejecting RegisterNotification if no transport exists

If no transport exists set the volume as 0, the real volume will be set
when a transport becomes available.

11 years agocore: Add workaround for device pairing kernel bug
Szymon Janc [Fri, 18 Jan 2013 11:51:35 +0000 (12:51 +0100)]
core: Add workaround for device pairing kernel bug

Some kernels reply to device pairing command with bogus command status
instead of command complete event if adapter was not powered.

Command status event doesn't provide remote device address and type
needed to properly complete bonding request.

Pass possibly missing data as user_data to mgmt_send and use it in
pair_device_complete function if needed.

11 years agotools: Add basic invalid params test case for mgmt_unblock_device
Johan Hedberg [Fri, 18 Jan 2013 13:15:34 +0000 (15:15 +0200)]
tools: Add basic invalid params test case for mgmt_unblock_device

11 years agotools: Add basic invalid params test case for mgmt_block_device
Johan Hedberg [Fri, 18 Jan 2013 13:14:31 +0000 (15:14 +0200)]
tools: Add basic invalid params test case for mgmt_block_device

11 years agotools: Add basic mgmt_disconnect invalid params test case
Johan Hedberg [Fri, 18 Jan 2013 13:01:48 +0000 (15:01 +0200)]
tools: Add basic mgmt_disconnect invalid params test case

11 years agotools: Add basic mgmt_unpair_device test cases
Johan Hedberg [Fri, 18 Jan 2013 12:56:16 +0000 (14:56 +0200)]
tools: Add basic mgmt_unpair_device test cases

11 years agotools: Add mgmt_pair_device test with invalid address type
Johan Hedberg [Fri, 18 Jan 2013 12:32:21 +0000 (14:32 +0200)]
tools: Add mgmt_pair_device test with invalid address type

11 years agotools: Add mgmt test case for pair device while powered off
Szymon Janc [Fri, 18 Jan 2013 12:20:41 +0000 (14:20 +0200)]
tools: Add mgmt test case for pair device while powered off

This tests if kernel is responding with proper command complete event.

11 years agotools: Add another invalid params mgmt_load_long_term_keys test
Johan Hedberg [Fri, 18 Jan 2013 12:14:13 +0000 (14:14 +0200)]
tools: Add another invalid params mgmt_load_long_term_keys test

11 years agotools: Add more mgmt_load_ltks invalid params tests
Johan Hedberg [Fri, 18 Jan 2013 12:05:41 +0000 (14:05 +0200)]
tools: Add more mgmt_load_ltks invalid params tests

11 years agoobexd: Add parameter Status to GetMessageListing response
Christian Fetzer [Tue, 15 Jan 2013 13:56:44 +0000 (14:56 +0100)]
obexd: Add parameter Status to GetMessageListing response

The parameter Status indicates the status of reception of the message.
It can be used to differentiate between messages with a reception status
of "completed", "fractioned" and "notification".

This parameter got lost when obexd was refactored to use of D-Bus properties.
The documentation and the parsing code for it was still there.

11 years agoobexd: Add parameter AttachmentSize to GetMessageListing response
Christian Fetzer [Tue, 15 Jan 2013 13:56:43 +0000 (14:56 +0100)]
obexd: Add parameter AttachmentSize to GetMessageListing response

The parameter AttachmentSize indicates if the message contains
any attachment and their overall size (in bytes).

11 years agoobexd: Add parameter Text to GetMessageListing response
Christian Fetzer [Tue, 15 Jan 2013 13:56:42 +0000 (14:56 +0100)]
obexd: Add parameter Text to GetMessageListing response

The Text flag indicates if the message contains any textual content
or has binary content only.

11 years agoobexd: Move parse_size function in map.c
Christian Fetzer [Tue, 15 Jan 2013 13:56:41 +0000 (14:56 +0100)]
obexd: Move parse_size function in map.c

This reorders msg_parsers and moves the function parse_size
to match the order in the MAP specification.

11 years agoobexd: Add parameter SubjectLength to map_list_messages
Christian Fetzer [Tue, 15 Jan 2013 13:56:40 +0000 (14:56 +0100)]
obexd: Add parameter SubjectLength to map_list_messages

This parameter allows the client to request a maximum length of the
parameter "subject" in the messages listing.

11 years agounit: Add gdbus/client_get_uint64_property
Luiz Augusto von Dentz [Fri, 11 Jan 2013 10:23:29 +0000 (12:23 +0200)]
unit: Add gdbus/client_get_uint64_property

11 years agounit: Add gdbus/client_get_array_property
Luiz Augusto von Dentz [Thu, 10 Jan 2013 13:09:23 +0000 (15:09 +0200)]
unit: Add gdbus/client_get_array_property

11 years agounit: Add gdbus/client_get_boolean_property
Luiz Augusto von Dentz [Thu, 10 Jan 2013 12:51:52 +0000 (14:51 +0200)]
unit: Add gdbus/client_get_boolean_property

11 years agounit: Add gdbus/client_get_string_property
Luiz Augusto von Dentz [Thu, 10 Jan 2013 10:36:04 +0000 (12:36 +0200)]
unit: Add gdbus/client_get_string_property

11 years agounit: Add gdbus/client_get_dict_property
Luiz Augusto von Dentz [Thu, 10 Jan 2013 09:28:16 +0000 (11:28 +0200)]
unit: Add gdbus/client_get_dict_property

11 years agotools: Add basic failure test case for mgmt_load_long_term_keys
Johan Hedberg [Fri, 18 Jan 2013 11:15:53 +0000 (13:15 +0200)]
tools: Add basic failure test case for mgmt_load_long_term_keys

11 years agotools: Add basic success test case for mgmt_load_long_term_keys
Johan Hedberg [Fri, 18 Jan 2013 11:14:09 +0000 (13:14 +0200)]
tools: Add basic success test case for mgmt_load_long_term_keys

11 years agotools: Add another invalid params test for mgmt_load_link_keys
Johan Hedberg [Fri, 18 Jan 2013 10:58:33 +0000 (12:58 +0200)]
tools: Add another invalid params test for mgmt_load_link_keys

11 years agodoc: Add note about Debug_Keys parameter for Load Link Keys Command
Johan Hedberg [Fri, 18 Jan 2013 10:56:15 +0000 (12:56 +0200)]
doc: Add note about Debug_Keys parameter for Load Link Keys Command

11 years agotools: Add basic invalid parameters test case for mgmt_load_link_keys
Johan Hedberg [Fri, 18 Jan 2013 09:26:07 +0000 (11:26 +0200)]
tools: Add basic invalid parameters test case for mgmt_load_link_keys

11 years agotools: Add initial success test cases for mgmt_load_link_keys
Johan Hedberg [Fri, 18 Jan 2013 09:16:49 +0000 (11:16 +0200)]
tools: Add initial success test cases for mgmt_load_link_keys

11 years agotools: Add temporary workaround for mgmt_set_powered kernel bug
Johan Hedberg [Fri, 18 Jan 2013 08:43:57 +0000 (10:43 +0200)]
tools: Add temporary workaround for mgmt_set_powered kernel bug

11 years agoshared: Add separate timed out test result
Johan Hedberg [Thu, 17 Jan 2013 21:13:49 +0000 (23:13 +0200)]
shared: Add separate timed out test result

11 years agotools: Use a timeout for all mgmt test cases
Johan Hedberg [Thu, 17 Jan 2013 13:56:46 +0000 (15:56 +0200)]
tools: Use a timeout for all mgmt test cases

11 years agotools: Fix EIR reference data to account for TX power in newer kernels
Johan Hedberg [Thu, 17 Jan 2013 12:28:56 +0000 (14:28 +0200)]
tools: Fix EIR reference data to account for TX power in newer kernels

11 years agotools: Add mgmt test case for multiple UUID-16 values
Johan Hedberg [Thu, 17 Jan 2013 11:58:21 +0000 (13:58 +0200)]
tools: Add mgmt test case for multiple UUID-16 values

11 years agoshared: Fix missing removal of test timeout for success/failure
Johan Hedberg [Thu, 17 Jan 2013 10:39:56 +0000 (12:39 +0200)]
shared: Fix missing removal of test timeout for success/failure

11 years agotools: Add basic add_uuid UUID-32 test case for mgmt-tester
Johan Hedberg [Thu, 17 Jan 2013 09:40:44 +0000 (11:40 +0200)]
tools: Add basic add_uuid UUID-32 test case for mgmt-tester

11 years agotools: Add basic add_uuid UUID-16 test case for mgmt-tester
Johan Hedberg [Thu, 17 Jan 2013 09:27:07 +0000 (11:27 +0200)]
tools: Add basic add_uuid UUID-16 test case for mgmt-tester

11 years agounit: Add advertising data from MIO Alpha heartrate watch for testing
Marcel Holtmann [Wed, 16 Jan 2013 18:50:17 +0000 (10:50 -0800)]
unit: Add advertising data from MIO Alpha heartrate watch for testing

11 years agotools: Define power off CoD test with a timeout
Johan Hedberg [Wed, 16 Jan 2013 15:11:02 +0000 (17:11 +0200)]
tools: Define power off CoD test with a timeout

11 years agotools: Add support for defining mgmt tests with a timeout
Johan Hedberg [Wed, 16 Jan 2013 15:08:58 +0000 (17:08 +0200)]
tools: Add support for defining mgmt tests with a timeout

11 years agoshared: Add timeout support for test cases
Johan Hedberg [Wed, 16 Jan 2013 15:07:43 +0000 (17:07 +0200)]
shared: Add timeout support for test cases

11 years agotools: Do more generic tracking of unmet test conditions in mgmt-tester
Johan Hedberg [Wed, 16 Jan 2013 14:52:02 +0000 (16:52 +0200)]
tools: Do more generic tracking of unmet test conditions in mgmt-tester

11 years agotools: Fix test for unset settings in mgmt-tester
Johan Hedberg [Wed, 16 Jan 2013 14:51:30 +0000 (16:51 +0200)]
tools: Fix test for unset settings in mgmt-tester

11 years agotools: Add power off test for testing correct class of dev
Johan Hedberg [Wed, 16 Jan 2013 13:55:16 +0000 (15:55 +0200)]
tools: Add power off test for testing correct class of dev

11 years agotools: Fix waiting for expected events in mgmt-tester
Johan Hedberg [Wed, 16 Jan 2013 13:54:26 +0000 (15:54 +0200)]
tools: Fix waiting for expected events in mgmt-tester

11 years agotools: Add class of device change monitoring support to mgmt-tester
Johan Hedberg [Wed, 16 Jan 2013 13:39:13 +0000 (15:39 +0200)]
tools: Add class of device change monitoring support to mgmt-tester

11 years agotools: Add basic power off test to mgmt-tester
Johan Hedberg [Wed, 16 Jan 2013 13:18:00 +0000 (15:18 +0200)]
tools: Add basic power off test to mgmt-tester

11 years agotools: Add mgmt-tester support for testing for unset settings
Johan Hedberg [Wed, 16 Jan 2013 13:17:20 +0000 (15:17 +0200)]
tools: Add mgmt-tester support for testing for unset settings

11 years agounit: Add tests for SDP integer Data Elements
Anderson Lizardo [Fri, 11 Jan 2013 01:22:02 +0000 (21:22 -0400)]
unit: Add tests for SDP integer Data Elements

SDP_DATA_NIL does not have a value, but its sdp_data_t val field is
zeroed by memset(), so just treat it as UINT8 with zero value to
simplify checking (and not require a separate macro.)

SDP_BOOL is handled by SDP library as a INT8.

SDP_UINT128/SDP_INT128 are just byte arrays converted to host order, so
use memcmp() to compare them (converting from host to network order
first.)

11 years agounit: Add {TEXT,URL}_STR{8,16} tests for sdp_extract_attr()
Anderson Lizardo [Fri, 11 Jan 2013 01:22:01 +0000 (21:22 -0400)]
unit: Add {TEXT,URL}_STR{8,16} tests for sdp_extract_attr()

These tests are for valid data. Other tests might be added later to
check for error paths, but will require separate macros.

{TEXT,URL}_STR32 cannot be tested with the same macros because
sdp_extract_attr() does not support them. They will be tested
separately with other SDP library functions.

As example of failure output, if commit
504a0cf46ad89cab8005ce9cffb22e41048f6a30 is reverted for testing, the
STR16 test will fail with:

ERROR:unit/test-sdp.c:776:test_sdp_de_attr: assertion failed
(test->input_size == size): (7 == 11)

11 years agotools: Add HCI command checking for mgmt_set_dev_class test
Johan Hedberg [Wed, 16 Jan 2013 12:34:32 +0000 (14:34 +0200)]
tools: Add HCI command checking for mgmt_set_dev_class test

11 years agocore: Fix checking for device object creation failures
Johan Hedberg [Wed, 16 Jan 2013 07:39:17 +0000 (09:39 +0200)]
core: Fix checking for device object creation failures

11 years agocore: Log device interface registration failures
Johan Hedberg [Wed, 16 Jan 2013 07:38:39 +0000 (09:38 +0200)]
core: Log device interface registration failures

11 years agomonitor: Differentiate between E0 and AES-CCM encryption
Marcel Holtmann [Wed, 16 Jan 2013 05:16:59 +0000 (21:16 -0800)]
monitor: Differentiate between E0 and AES-CCM encryption

11 years agotools: Add some basic mgmt_set_dev_class test cases
Johan Hedberg [Tue, 15 Jan 2013 20:29:01 +0000 (22:29 +0200)]
tools: Add some basic mgmt_set_dev_class test cases

11 years agotools: Add some basic mgmt_start_discovery failure test cases
Johan Hedberg [Tue, 15 Jan 2013 19:15:38 +0000 (21:15 +0200)]
tools: Add some basic mgmt_start_discovery failure test cases

11 years agoAVRCP: Fix sending volume changed when not registered
Luiz Augusto von Dentz [Tue, 15 Jan 2013 13:38:54 +0000 (15:38 +0200)]
AVRCP: Fix sending volume changed when not registered

Notifications should only be sent if remote device has registered using
RegisterNotification.

11 years agoAVRCP: Check version before sending volume changed event/SetAbsoluteVolume
Luiz Augusto von Dentz [Tue, 15 Jan 2013 13:20:02 +0000 (15:20 +0200)]
AVRCP: Check version before sending volume changed event/SetAbsoluteVolume

Volume change event and SetAbsoluteVolume command are only available
starting from 1.4, so we should not attempt to send these commands for
versions before that.

11 years agoaudio: Bump AVRCP CT version to 1.5
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:34 +0000 (17:25 -0300)]
audio: Bump AVRCP CT version to 1.5

11 years agoavrcp: Handle SetAbsoluteVolume command
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:33 +0000 (17:25 -0300)]
avrcp: Handle SetAbsoluteVolume command

11 years agotransport: Update volume passing only audio_device
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:32 +0000 (17:25 -0300)]
transport: Update volume passing only audio_device

11 years agoavrcp: Notify remote of volume changes
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:31 +0000 (17:25 -0300)]
avrcp: Notify remote of volume changes

11 years agoavrcp: Handle RegisterNotification for volume
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:30 +0000 (17:25 -0300)]
avrcp: Handle RegisterNotification for volume

This commit answers a NOTIFY command to register for nofications of
EVENT_VOLUME_CHANGED with an INTERIM response containing the current
absolute volume value.

11 years agotransport: Get volume passing only audio_device
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:29 +0000 (17:25 -0300)]
transport: Get volume passing only audio_device

11 years agotransport: Keep a list o all existent transports
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:28 +0000 (17:25 -0300)]
transport: Keep a list o all existent transports

11 years agotransport: Get volume from transport
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:27 +0000 (17:25 -0300)]
transport: Get volume from transport

11 years agoavrcp: Add EVENT_VOLUME_CHANGED to CT capabilities
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:26 +0000 (17:25 -0300)]
avrcp: Add EVENT_VOLUME_CHANGED to CT capabilities

11 years agotransport: Store the value set through the 'Volume' property
João Paulo Rechi Vita [Fri, 11 Jan 2013 20:25:25 +0000 (17:25 -0300)]
transport: Store the value set through the 'Volume' property

11 years agotransport: Initialize the "Volume" property
João Paulo Rechi Vita [Mon, 14 Jan 2013 16:10:29 +0000 (13:10 -0300)]
transport: Initialize the "Volume" property

11 years agocore: Fix handling mgmt socket write failures
Johan Hedberg [Tue, 15 Jan 2013 17:46:04 +0000 (19:46 +0200)]
core: Fix handling mgmt socket write failures

If a write to the socket fails we should properly notify the command
callback and remove the command from the queue.

11 years agocore: Move valid discovery type check to mgmt_start_discovery
Johan Hedberg [Tue, 15 Jan 2013 14:19:47 +0000 (16:19 +0200)]
core: Move valid discovery type check to mgmt_start_discovery

11 years agocore: Fix connect list usage for non-LE adapters
Johan Hedberg [Tue, 15 Jan 2013 13:46:56 +0000 (15:46 +0200)]
core: Fix connect list usage for non-LE adapters

11 years agocore: Don't try to start discovery with invalid address type
Johan Hedberg [Tue, 15 Jan 2013 12:41:25 +0000 (14:41 +0200)]
core: Don't try to start discovery with invalid address type

11 years agocore: Add more debug logs to start_discovery functions
Johan Hedberg [Tue, 15 Jan 2013 12:38:18 +0000 (14:38 +0200)]
core: Add more debug logs to start_discovery functions

11 years agocore: Add debug log to mgmt_start_discovery()
Johan Hedberg [Tue, 15 Jan 2013 11:56:49 +0000 (13:56 +0200)]
core: Add debug log to mgmt_start_discovery()

11 years agotools: Fix map-client to use new print syntax
Luiz Augusto von Dentz [Mon, 14 Jan 2013 15:39:28 +0000 (17:39 +0200)]
tools: Fix map-client to use new print syntax

print now requires () on newer python:
  File "./map-client", line 101
    print err
            ^

11 years agoobexd: Remove transferred file only if the GET operation failed
Christian Fetzer [Fri, 11 Jan 2013 15:55:57 +0000 (16:55 +0100)]
obexd: Remove transferred file only if the GET operation failed

Since 9606375649e12f1b9f302bbb5bb8f87957387ddd xfer_complete() sets the
transfer status rather than the size. Adapt obc_transfer_free to check
for the completed status to avoid deletion of completed transfers.

11 years agoobexd: Change behavior of parse_filter_read
Christian Fetzer [Fri, 11 Jan 2013 15:55:56 +0000 (16:55 +0100)]
obexd: Change behavior of parse_filter_read

Calls to ListMessages with filter 'Read' set to true should
request the MSE to send read messages only.

The old code requests the MSE to send unread messages only.
This behavior is not matching the other filters.

11 years agoobexd: Use defines for values in parse_filter_read parse_filter_priority
Christian Fetzer [Fri, 11 Jan 2013 15:55:55 +0000 (16:55 +0100)]
obexd: Use defines for values in parse_filter_read parse_filter_priority

11 years agoobexd: Fix segfault in parse_filter_read and parse_filter_priority
Christian Fetzer [Fri, 11 Jan 2013 15:55:54 +0000 (16:55 +0100)]
obexd: Fix segfault in parse_filter_read and parse_filter_priority

Calls to ListMessages with filter 'Read' or 'Priority' caused a segfault
in parse_filter_read / parse_filter_priority. The functions read
D-Bus boolean values (uint32) into uint8.

0  0x00007ffff730332d in ?? () from /usr/lib/libdbus-1.so.3
1  0x00007ffff7304219 in dbus_message_iter_next () from /usr/lib/libdbus-1.so.3
2  0x000000000043ef0f in parse_message_filters (
    apparam=<error reading variable: Cannot access memory at address 0x7ffffeffff08>,
    iter=<error reading variable: Cannot access memory at address 0x7ffffeffff00>)
    at obexd/client/map.c:1246

11 years agoobexd: Fix FILTER_ALL in MAP client to set 16 bit
Christian Fetzer [Fri, 11 Jan 2013 15:55:53 +0000 (16:55 +0100)]
obexd: Fix FILTER_ALL in MAP client to set 16 bit

The MAP specification defines ParameterMask as a bitmask of 32 bit / 4 bytes.
For the lower 16 bit the specification defines parameters, the higher 16 bit
remain reserved for future use. Therefore FILTER_ALL is set to 0x0000FFFF.
(Reserved bits have to be set to 0)

In addition this fixes the issue that ListFilterFields didn't show all fields.

11 years agoobexd: Fix infinite loop in ListMessages with filter "Types"
Christian Fetzer [Fri, 11 Jan 2013 15:55:52 +0000 (16:55 +0100)]
obexd: Fix infinite loop in ListMessages with filter "Types"

Calls to ListMessages with filter 'Types' make obexd hang in an infinite loop.
This is caused by a missing dbus_message_iter_next in parse_filter_type.

0  0x00007ffff7304ca7 in dbus_message_iter_get_basic ()
   from /usr/lib/libdbus-1.so.3
1  0x0000000000434fba in parse_filter_type (iter=0x7fffffffd7d0, apparam=
    0x6987f0) at obexd/client/map.c:1086
2  parse_message_filters (iter=0x7fffffffd730, apparam=0x6987f0)
    at obexd/client/map.c:1222
3  map_list_messages (connection=<optimized out>, message=0x669ae0, user_data=
    0x698a60) at obexd/client/map.c:1273
4  0x00000000004109a1 in process_message (connection=0x662b20,
    message=<optimized out>, iface_user_data=<optimized out>,
    method=<optimized out>, method=<optimized out>) at gdbus/object.c:285
5  0x00007ffff7308e15 in ?? () from /usr/lib/libdbus-1.so.3
6  0x00007ffff72fb070 in dbus_connection_dispatch ()
   from /usr/lib/libdbus-1.so.3
7  0x000000000040e3d8 in message_dispatch (data=0x662b20)
    at gdbus/mainloop.c:76
8  0x00007ffff703d3cb in ?? () from /usr/lib/libglib-2.0.so.0
9  0x00007ffff703c845 in g_main_context_dispatch ()
   from /usr/lib/libglib-2.0.so.0
10 0x00007ffff703cb78 in ?? () from /usr/lib/libglib-2.0.so.0
11 0x00007ffff703cf72 in g_main_loop_run () from /usr/lib/libglib-2.0.so.0
12 0x000000000040df82 in main (argc=1, argv=0x7fffffffdd88)
    at obexd/src/main.c:323

11 years agoobexd: Add property exist functions to map client
Christian Fetzer [Fri, 11 Jan 2013 15:55:51 +0000 (16:55 +0100)]
obexd: Add property exist functions to map client

This fixes crashes in MAP client when the server does not send optional properties.

0  0x00007ffff6a792c5 in raise () from /usr/lib/libc.so.6
1  0x00007ffff6a7a748 in abort () from /usr/lib/libc.so.6
2  0x00007ffff731c145 in ?? () from /usr/lib/libdbus-1.so.3
3  0x00007ffff7312a25 in ?? () from /usr/lib/libdbus-1.so.3
4  0x00007ffff73050d6 in dbus_message_iter_append_basic () from /usr/lib/libdbus-1.so.3
5  0x0000000000433cc5 in get_replyto (property=<optimized out>, iter=<optimized out>,
    data=<optimized out>) at obexd/client/map.c:484
6  0x00000000004103b6 in append_property (p=p@entry=0x6594c0 <map_msg_properties+192>,
    dict=dict@entry=0x7fffffffd8e0, iface=0x6a3720) at gdbus/object.c:547
7  0x0000000000410472 in append_properties (data=data@entry=0x6a3720, iter=iter@entry=
    0x7fffffffd960) at gdbus/object.c:576
8  0x00000000004104d1 in append_interface (data=0x6a3720, user_data=0x7fffffffda40)
    at gdbus/object.c:591
9  0x00007ffff7058a4d in g_slist_foreach () from /usr/lib/libglib-2.0.so.0
10 0x0000000000411d05 in emit_interfaces_added (data=0x6a2ff0) at gdbus/object.c:623
11 process_changes (user_data=0x6a2ff0) at gdbus/object.c:1006
12 0x00007ffff703c845 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
13 0x00007ffff703cb78 in ?? () from /usr/lib/libglib-2.0.so.0
14 0x00007ffff703cf72 in g_main_loop_run () from /usr/lib/libglib-2.0.so.0
15 0x000000000040df82 in main (argc=1, argv=0x7fffffffdd88) at obexd/src/main.c:323

11 years agoobexd: Handle empty path name in SetPath
Christian Fetzer [Fri, 11 Jan 2013 15:55:50 +0000 (16:55 +0100)]
obexd: Handle empty path name in SetPath

If the empty path is given, an empty name should be sent via OBEX.
Currently the name field is not set at all and later checks which
depend on data->index will access invalid memory regions as g_strsplit
returns NULL when an empty string is given.

0  0x000000000041a181 in g_obex_setpath (obex=obex@entry=0x662eb0, path=
    0x20 <Address 0x20 out of bounds>, func=func@entry=0x42d300 <setpath_cb>,
    user_data=user_data@entry=0x668f10, err=err@entry=0x7fffffffda08)
    at gobex/gobex.c:1397
1  0x000000000042d395 in setpath_cb (obex=0x662eb0, err=0x0, rsp=<optimized out>,
    user_data=0x668f10) at obexd/client/session.c:902
2  0x0000000000418e54 in handle_response (obex=obex@entry=0x662eb0, err=err@entry=0x0,
    rsp=rsp@entry=0x668f40) at gobex/gobex.c:948
3  0x0000000000419d7a in incoming_data (io=<optimized out>, cond=<optimized out>,
    user_data=0x662eb0) at gobex/gobex.c:1191
4  0x00007ffff703c845 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
5  0x00007ffff703cb78 in ?? () from /usr/lib/libglib-2.0.so.0
6  0x00007ffff703cf72 in g_main_loop_run () from /usr/lib/libglib-2.0.so.0
7  0x000000000040def2 in main (argc=1, argv=0x7fffffffdd88) at obexd/src/main.c:323

11 years agodoc: Fix trivial typo in adapter-api
Mikel Astiz [Mon, 14 Jan 2013 07:44:41 +0000 (08:44 +0100)]
doc: Fix trivial typo in adapter-api

11 years agomonitor: Add decoding for minor class for wearable major class
Marcel Holtmann [Mon, 14 Jan 2013 07:48:29 +0000 (23:48 -0800)]
monitor: Add decoding for minor class for wearable major class

11 years agocore: Rename adapter->disc_sessions to discov_sessions for clarity
Johan Hedberg [Mon, 14 Jan 2013 07:24:56 +0000 (09:24 +0200)]
core: Rename adapter->disc_sessions to discov_sessions for clarity

11 years agomonitor: Add GATT-based Service UUIDs
Marcel Holtmann [Mon, 14 Jan 2013 02:47:49 +0000 (18:47 -0800)]
monitor: Add GATT-based Service UUIDs

11 years agomonitor: Add UUID values for Characteristic Descriptors
Marcel Holtmann [Mon, 14 Jan 2013 02:39:31 +0000 (18:39 -0800)]
monitor: Add UUID values for Characteristic Descriptors

11 years agomonitor: Add UUID values for Characteristic Descriptions
Marcel Holtmann [Mon, 14 Jan 2013 02:37:37 +0000 (18:37 -0800)]
monitor: Add UUID values for Characteristic Descriptions

11 years agomonitor: Fix the singular entry vs plural entries
Marcel Holtmann [Mon, 14 Jan 2013 02:07:46 +0000 (18:07 -0800)]
monitor: Fix the singular entry vs plural entries

11 years agomonitor: Decode the minor class field for major class phone
Marcel Holtmann [Mon, 14 Jan 2013 02:03:37 +0000 (18:03 -0800)]
monitor: Decode the minor class field for major class phone

11 years agomonitor: Decode 16-bit and 32-bit UUID values from EIR data
Marcel Holtmann [Mon, 14 Jan 2013 01:59:24 +0000 (17:59 -0800)]
monitor: Decode 16-bit and 32-bit UUID values from EIR data