Commit Graph

1141 Commits

Author SHA1 Message Date
Johan Hedberg
91c50f7fa1 obexd: Merge obex-client into obexd daemon 2012-12-18 17:54:43 +02:00
Johan Hedberg
6934437fc7 obexd: Add client prefix to client manager functions
This is in preparation of merging the client into the daemon.
2012-12-18 16:03:42 +02:00
Luiz Augusto von Dentz
3eadc034c9 obex-client: Make use of g_dbus_get_properties to get transfer properties
In addition fix the reply generated by obc_transfer_create_dbus_reply to
not use a structure container instead use object, dict 'oa{sv}' as
indicated in the documentation.
2012-12-17 16:31:59 +02:00
Luiz Augusto von Dentz
27635e590b obex-client: Enable ObjectManager 2012-12-17 14:10:36 +02:00
Luiz Augusto von Dentz
e4cc2de1c7 obexd: Remove SessionCreated and SessionRemoved signals
With ObjectManager these signals no longer are necessary.
2012-12-17 14:10:34 +02:00
Luiz Augusto von Dentz
54f6035e45 obexd: Enable ObjectManager 2012-12-17 14:10:32 +02:00
Luiz Augusto von Dentz
b8972b65e5 obexd: Port session interface to use D-Bus Properties 2012-12-17 14:10:30 +02:00
Luiz Augusto von Dentz
e4f45a247b obex-client: Port transfer code to use D-Bus properties interface 2012-12-16 13:26:02 +02:00
Luiz Augusto von Dentz
6f5797da8b obex-client: Port session code to use D-Bus properties interface 2012-12-16 13:26:00 +02:00
Luiz Augusto von Dentz
82a76393fe obex-client: Port MAP module to use D-Bus properties interface 2012-12-16 13:25:57 +02:00
Luiz Augusto von Dentz
0fea59d098 build: Remove obexd usb plugin
This plugin is not longer maintained and used to work only in meego
times.
2012-12-13 14:23:59 +02:00
Marcel Holtmann
05f9475f66 obexd: Fix build breakage from profile conversion 2012-12-12 23:21:02 +01:00
Luiz Augusto von Dentz
326376321f obex-client: Remove calls to org.bluez.Manager and org.bluez.Adapter
With BlueZ 5 this API no longer exist or have changed.
2012-12-12 14:20:12 +02:00
Luiz Augusto von Dentz
6d326f3768 irmc: Remove record details
Standart service records are already supported by bluetoothd
2012-12-12 13:57:45 +02:00
Luiz Augusto von Dentz
57c994a273 mas: Remove record details
Standart service records are already supported by bluetoothd
2012-12-12 13:57:43 +02:00
Luiz Augusto von Dentz
df56abd1e9 pbap: Remove record details
Standart service records are already supported by bluetoothd
2012-12-12 13:57:41 +02:00
Luiz Augusto von Dentz
19040c9f72 ftp: Remove record details
Standart service records are already supported by bluetoothd
2012-12-12 13:57:39 +02:00
Luiz Augusto von Dentz
9106f01fe5 opp: Remove record details
Standart service records are already supported by bluetoothd
2012-12-12 13:57:37 +02:00
Luiz Augusto von Dentz
b06089c493 obexd: Add support for custom records
Services such as pcsuite and syncml use custom records not defined by
Bluetooth SIG so they have to be registered using ServiceRecord entry.
2012-12-12 13:57:34 +02:00
Luiz Augusto von Dentz
40b2cc329c obexd: Enable support SYNC profile 2012-12-12 13:57:15 +02:00
Luiz Augusto von Dentz
1abed724ce obexd: Enable support for MAS profile 2012-12-12 13:57:13 +02:00
Luiz Augusto von Dentz
23b28ab759 obexd: Port bluetooth plugin to use external profile support
This changes obexd to use ProfileManager.RegisterProfile
2012-12-12 13:56:12 +02:00
Marcel Holtmann
3539054aa9 obexd: Don't daemonize and just toggle foreground logging 2012-12-10 23:16:49 +01:00
Johan Hedberg
b8779d2202 Revert "Ensure config.h is included by using CPPFLAGS"
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
2012-12-07 12:46:04 +02:00
Lucas De Marchi
0375042892 Use entire include path for gobex.h 2012-12-05 17:23:04 +02:00
Lucas De Marchi
5714b14bce Reorder btio.h includes
Let "#include <btio/btio.h>" together with other includes using '<'
rather than '"'.
2012-12-05 17:23:04 +02:00
Lucas De Marchi
49b5612042 Use the entire include path for btio.h 2012-12-05 17:23:04 +02:00
Lucas De Marchi
aa77b0bea9 Use the entire include path for gdbus.h 2012-12-05 17:23:03 +02:00
Lucas De Marchi
8a03376544 Ensure config.h is included by using CPPFLAGS
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.
2012-12-05 17:18:07 +02:00
Marcel Holtmann
41aa85d123 build: Compile obexd and obex-client 2012-12-04 23:38:48 +01:00
Luiz Augusto von Dentz
ff3d8766b7 obexd: Fix using BtIOType 2012-12-04 22:49:06 +01:00
Luiz Augusto von Dentz
cdfaf26ea9 obexd: Fix using BtIOType 2012-12-04 22:49:06 +01:00
Sunil Kumar Behera
ab156cd3c5 obexd: Add get_next_header() in message listing
In case of message listing we need to send application
parameters in response and also it is required for sending
response to message listing size request.
2012-12-04 22:49:06 +01:00
Sunil Kumar Behera
2ee7238d8f obexd: Reset ap_sent variable
For multiple subsequent request for message listing
we need to reset this variable to FALSE, so that each
time the get next header function is executed properly.
2012-12-04 22:49:06 +01:00
Luiz Augusto von Dentz
f3eeb2c93f obexd: Fix sending absolute path
As per OBEX spec the NAME header should not contain absolute paths
2012-12-04 22:49:06 +01:00
Luiz Augusto von Dentz
1f4a67568c obexd: Fix returning empty if messages was already listed
Once a message was already listed and inserted on the cache it could
not be listed again as the code was using the wrong key to lookup for
found messages then once we try to create the message again it fails
as the object already exists.
2012-12-04 22:49:06 +01:00
Luiz Augusto von Dentz
33b0aeda71 obexd: Fix freeing apparam data on PBAP module
Invalid read of size 8
   at 0x40EC04: g_obex_apparam_free (gobex-apparam.c:362)
   by 0x41A66A: obc_transfer_free (transfer.c:272)
   by 0x413221: pending_request_free (session.c:163)
   by 0x413659: session_terminate_transfer (session.c:745)
   by 0x41A53E: xfer_complete (transfer.c:518)
   by 0x41B5D7: get_xfer_progress_first (transfer.c:562)
   by 0x409750: handle_response (gobex.c:948)
   by 0x40A609: incoming_data (gobex.c:1191)
   by 0x371D047824: g_main_context_dispatch (in /usr/lib64/libglib-2.0.so.0.3200.4)
   by 0x371D047B57: ??? (in /usr/lib64/libglib-2.0.so.0.3200.4)
   by 0x371D047F51: g_main_loop_run (in /usr/lib64/libglib-2.0.so.0.3200.4)
   by 0x40542F: main (main.c:175)
 Address 0x4f64510 is 0 bytes inside a block of size 8 free'd
   at 0x4A079AE: free (vg_replace_malloc.c:427)
   by 0x371D04D50E: g_free (in /usr/lib64/libglib-2.0.so.0.3200.4)
   by 0x416060: phonebook_size_callback (pbap.c:266)
   by 0x413651: session_terminate_transfer (session.c:743)
   by 0x41A53E: xfer_complete (transfer.c:518)
   by 0x41B5D7: get_xfer_progress_first (transfer.c:562)
   by 0x409750: handle_response (gobex.c:948)
   by 0x40A609: incoming_data (gobex.c:1191)
   by 0x371D047824: g_main_context_dispatch (in /usr/lib64/libglib-2.0.so.0.3200.4)
   by 0x371D047B57: ??? (in /usr/lib64/libglib-2.0.so.0.3200.4)
   by 0x371D047F51: g_main_loop_run (in /usr/lib64/libglib-2.0.so.0.3200.4)
   by 0x40542F: main (main.c:175)
2012-12-04 22:49:06 +01:00
Luiz Augusto von Dentz
f1e88405c0 obexd: Fix not using port when it is set by the client
If the client set a channel/port the code would just ignore and attempt
to discover the service anyway.
2012-12-04 22:49:06 +01:00
Srinivasa Ragavan
d77a640090 obexd: Add implementation for UpdateInbox 2012-12-04 22:49:06 +01:00
Luiz Augusto von Dentz
ea5d38411a obexd: Fix build when using --with-messages=tracker
Commit 15b15167fb2dd82e2189cc1955def1818a7bc6a6 broke the build:

plugins/messages.c:324:42: error: unknown type name ‘messages_update_inbox_cb’
plugins/messages.c:331:5: error: unknown type name ‘messages_set_read_cb’
plugins/messages.c:337:6: error: unknown type name ‘messages_set_delete_cb’
2012-12-04 22:49:06 +01:00
Srinivasa Ragavan
920bbb3663 obexd: Add Message.SetProperty and Message.GetProperties implementation. 2012-12-04 22:49:05 +01:00
Srinivasa Ragavan
3ab485ec08 obexd: Update the file offset to the beginning after writing to the file
When the transfer file is opened in O_RDWR mode, just after the contents are
written to the file, the file offset has to be set to the beginning of the
file. If not subsequent read fails. This patch fixes this.
2012-12-04 22:49:05 +01:00
Luiz Augusto von Dentz
a103426e51 obexd: Make obc_transfer_put to accept NULL as filename
In that case contents should be valid so the modules can use
obc_transfer_put to create temporary files.
2012-12-04 22:49:05 +01:00
Luiz Augusto von Dentz
36d387af61 obexd: Avoid extra copies while passing apparam to transfer
By passing directly the reference to GObexApparam it is no longer
necessary to use intermediate buffers to pass data around.
2012-12-04 22:49:05 +01:00
Luiz Augusto von Dentz
d1db67a33b obexd: Fix not sending parameters to get message in map module
Attachment and charset are mandatory, so Message.Get now takes an
additional boolean parameter which the user application should set
if it wants the attachments to be downloaded, charset is always set
to UTF8.
2012-12-04 22:49:05 +01:00
Luiz Augusto von Dentz
7eac453589 obexd: Add MessageAccess.ListFilterFields 2012-12-04 22:49:05 +01:00
Luiz Augusto von Dentz
45779d1a57 obexd: Rename MessageAccess method GetMessagesListing to ListMessages
In addition to that add missing parsing of the filters
2012-12-04 22:49:05 +01:00
Luiz Augusto von Dentz
16d0190ea7 obexd: Rename MessageAccess method GetFolderListing to ListFolders
In addition to that add missing parsing of the filters.
2012-12-04 22:49:05 +01:00
Luiz Augusto von Dentz
0155c14fb2 obexd: Use larger timeout first packet in transfers
This align the client timeout for GET operations with g_obex_get_req_pkt
which does use 60 seconds to cover for extra interaction during the first
packet.
2012-12-04 22:49:05 +01:00
Luiz Augusto von Dentz
e24161f526 obexd: Unify callbacks for operations that only report status
This removes duplicated code.
2012-12-04 22:49:05 +01:00