summaryrefslogtreecommitdiff
path: root/tools/test-server.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@intel.com>2011-07-04 23:32:43 +0300
committerJohan Hedberg <johan.hedberg@intel.com>2011-07-16 17:50:46 +0300
commit9a87089cc971c1e9e618d051cc495a69bebd70f2 (patch)
tree2f0860f8b3f462135adb5542cd3d956b82ca8f6c /tools/test-server.c
parent41022325d4a3d707652130879450a93f335b8a0f (diff)
downloadobexd-9a87089cc971c1e9e618d051cc495a69bebd70f2.tar.gz
gobex: Use opcode instead of entire req in g_obex_response
Diffstat (limited to 'tools/test-server.c')
-rw-r--r--tools/test-server.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/test-server.c b/tools/test-server.c
index f82daad..1567c4e 100644
--- a/tools/test-server.c
+++ b/tools/test-server.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)