OSDN Git Service
(root)
/
android-x86
/
external-bluetooth-bluez.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1e00bd8
)
gobex: fix setting final bit on PUT requests
author
Luiz Augusto von Dentz
<luiz.von.dentz@intel.com>
Fri, 26 Aug 2011 09:49:32 +0000
(12:49 +0300)
committer
Marcel Holtmann
<marcel@holtmann.org>
Tue, 4 Dec 2012 21:22:02 +0000
(22:22 +0100)
Final bit should not be set when creating new request packets for PUT
since it may be not be the end of the body.
gobex/gobex-transfer.c
patch
|
blob
|
history
diff --git
a/gobex/gobex-transfer.c
b/gobex/gobex-transfer.c
index
fad641b
..
edf9992
100644
(file)
--- a/
gobex/gobex-transfer.c
+++ b/
gobex/gobex-transfer.c
@@
-170,10
+170,14
@@
static void transfer_response(GObex *obex, GError *err, GObexPacket *rsp,
return;
}
- req = g_obex_packet_new(transfer->opcode, TRUE, G_OBEX_HDR_INVALID);
-
- if (transfer->opcode == G_OBEX_OP_PUT)
+ if (transfer->opcode == G_OBEX_OP_PUT) {
+ req = g_obex_packet_new(transfer->opcode, FALSE,
+ G_OBEX_HDR_INVALID);
g_obex_packet_add_body(req, put_get_data, transfer);
+ } else {
+ req = g_obex_packet_new(transfer->opcode, TRUE,
+ G_OBEX_HDR_INVALID);
+ }
transfer->req_id = g_obex_send_req(obex, req, -1, transfer_response,
transfer, &err);