obexd/opp: Fix OPP GET request path 30/49830/1
authorGowtham Anandha Babu <gowtham.ab@samsung.com>
Tue, 20 Oct 2015 12:29:31 +0000 (17:59 +0530)
committerGowtham Anandha Babu <gowtham.ab@samsung.com>
Tue, 20 Oct 2015 12:29:31 +0000 (17:59 +0530)
commit29c14c770d4d883a84235ad6c43065272f2683e6
tree36189fa2345a81e1755d1edd7d994170fde90695
parent22add5ca2424beb1c72a56b0cea895e54ee194c5
obexd/opp: Fix OPP GET request path

The default path is /etc/bluetooth/vcard.vcf which obexd
is not able to access.

obexd[11654]: obexd/src/obex.c:cmd_get() session 0x64edff0
obexd[11654]: GET(0x3), (null)(0xffffffff)
obexd[11654]: obexd/src/obex.c:parse_type() TYPE: text/x-vcard
obexd[11654]: open(/etc/bluetooth/vcard.vcf): Operation not permitted (1)
obexd[11654]: GET(0x3), NOT_FOUND(0x44)

After making this path as obex root folder,
it is able to succeed.

obexd[12246]: obexd/src/obex.c:cmd_get() session 0x64ed830
obexd[12246]: GET(0x3), (null)(0xffffffff)
obexd[12246]: obexd/src/obex.c:parse_type() TYPE: text/x-vcard
obexd[12246]: obexd/src/obex.c:driver_get_headers() name=(null) type=text/x-vcard object=0x8
obexd[12246]: GET(0x3), CONTINUE(0x10)
obexd[12246]: obexd/src/obex.c:send_data() name=(null) type=text/x-vcard file=0x8 size=3061
obexd[12246]: obexd/src/obex.c:driver_read() 73 read
obexd[12246]: obexd/src/obex.c:send_data() name=(null) type=text/x-vcard file=0x8 size=3066
obexd[12246]: obexd/src/obex.c:driver_read() 0 read
obexd[12246]: obexd/src/obex.c:transfer_complete()

Git repo link:
https://git.kernel.org/cgit/bluetooth/bluez.git/commit/?id=fd524d73a3a83b8e324b14c166670e0326bc3946

Change-Id: I3a3bfca7a879af3fa19ceff17d6b4b1372949438
obexd/plugins/opp.c