summaryrefslogtreecommitdiff
path: root/tools/obex-server-tool.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@intel.com>2011-07-04 23:32:43 +0300
committerMarcel Holtmann <marcel@holtmann.org>2012-12-04 22:21:59 +0100
commit2e49852cceb9fa6e1f72f01f488184635a940564 (patch)
tree2718d8afab065c2ebd5804ad9ff3c1e5d98c0144 /tools/obex-server-tool.c
parent0fb35029cf90d196c429b58a7702ba5a8fba9133 (diff)
downloadbluez-2e49852cceb9fa6e1f72f01f488184635a940564.tar.gz
gobex: Use opcode instead of entire req in g_obex_response
Diffstat (limited to 'tools/obex-server-tool.c')
-rw-r--r--tools/obex-server-tool.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/obex-server-tool.c b/tools/obex-server-tool.c
index f82daad4b..1567c4ec9 100644
--- a/tools/obex-server-tool.c
+++ b/tools/obex-server-tool.c
@@ -63,9 +63,12 @@ static void disconn_func(GObex *obex, GError *err, gpointer user_data)
static void req_func(GObex *obex, GObexPacket *req, gpointer user_data)
{
- g_print("Request 0x%02x\n", g_obex_packet_get_operation(req, NULL));
+ gboolean final;
+ guint8 op = g_obex_packet_get_operation(req, &final);
- g_obex_response(obex, req, G_OBEX_RSP_SUCCESS, NULL, NULL);
+ g_print("Request 0x%02x%s\n", op, final ? " (final)" : "");
+
+ g_obex_response(obex, op, G_OBEX_RSP_SUCCESS, NULL, NULL);
}
static gboolean unix_accept(GIOChannel *chan, GIOCondition cond, gpointer data)