From e6ee77aedf213d2d351f0561e20ce93a235e6bc1 Mon Sep 17 00:00:00 2001 From: Johan Hedberg Date: Mon, 27 Jun 2011 01:42:43 +0300 Subject: [PATCH] gobex: Fix checking opcodes with final-bit set --- gobex/gobex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gobex/gobex.c b/gobex/gobex.c index 3874f1be2..c777ef677 100644 --- a/gobex/gobex.c +++ b/gobex/gobex.c @@ -423,7 +423,7 @@ void g_obex_packet_free(GObexPacket *pkt) static ssize_t get_header_offset(guint8 opcode) { - switch (opcode) { + switch (opcode & ~G_OBEX_FINAL) { case G_OBEX_OP_CONNECT: return sizeof(struct connect_data); case G_OBEX_OP_SETPATH: -- 2.47.3