This reverts commit 8a03376544.
The patch needs to be split up and the gdbus/ changes were bogus
compared to the original commit message.
Conflicts:
Makefile.am
Makefile.obexd
profiles/cyclingspeed/cyclingspeed.c
profiles/heartrate/heartrate.c
src/error.c
This patch changes store_adapter_info helper so it stores Discoverable
value according to discov_timeout. If discov_timeout is greater than
zero, we store "false" for Discoverable. This change covers the case
when DiscoverableTimeout value is set when Discoverable is true.
If adapter was set to Discoverable and DiscoverableTimeout is greater
than zero we should not store the Discoverable adapter info as long as
it is a non-persistent state. This way, we don't need to worry about
updating the Discoverable stored value once the timeout expires.
If we unplug an adapter in powered on state, once it is plugged
again, it doesn't go to powered on state as expected. This bug
happens because Powered info is stored when the adapter is
unplugged from the system.
This patch fixes this bug by only storing adapter info if mode
changing was requested by user application via D-Bus interface.
This patch basically reverts the changes in commit
985d8ac397 where the bug was
introduced.
Traceback (most recent call last):
File "./simple-agent", line 12, in <module>
import bluezutils
File "/home/fdanis/src/bluez/test/bluezutils.py", line 22
if not pattern or pattern == adapter["Address"] or
^
SyntaxError: invalid syntax
The property getter and setter belong to org.freedesktop.DBus.Properties
and therefore fix this code using the wrong interface since commit
67dab2d2ae.
Split the Acquire() method in two parts so that the optional acquires,
formerly represented as a "?" flag in the accesstype parameter of
Acquire(), are now implemented in TryAcquire().
There is no known use-case making use of these access types and
therefore the Media API can be simplified.
From now on, the transport will always be acquired with read and write
access rights.
If we don't force the symlink creation the build fails when the link
already exists. This happens if the rule to create the link is triggered
again because the file it points to changed. This is the case when doing
incremental builds and we modified the file.
$ make
$ touch lib/cmtp.h
$ make
GEN lib/bluetooth/cmtp.h
ln: failed to create symbolic link ‘lib/bluetooth/cmtp.h’: File exists
make: *** [lib/bluetooth/cmtp.h] Error 1
make: *** Waiting for unfinished jobs....
test/l2test.c:106:12: error: ‘encrypt’ redeclared as different kind of symbol
In file included from test/l2test.c:30:0:
/usr/include/unistd.h:1147:13: note: previous declaration of ‘encrypt’ was here
Instead of trying to include config.h in each file over the tree and
possibly forgetting to include it, give a "-include config.h" argument
to the compiler so it's guaranteed that a) it will be included for all
source files and b) it will be the first header included.
gdbus/ directory is left out, since it would break other projects using
it.
Instead of defining _GNU_SOURCE in each source file (and potentially
forgetting in some), tell the build system we use extensions and let it
define _GNU_SOURCE in config.h.