diff options
author | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2012-08-09 13:32:29 +0300 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2012-12-04 22:22:06 +0100 |
commit | 696fad1853ae83c71c9716bcf7302b3be49207ff (patch) | |
tree | 31aeb9c8c1d06006e5f1841cd0fec5015c7beaf0 /gobex/gobex.c | |
parent | d947e0718a132a7955388782f93a616944eb70bb (diff) | |
download | bluez-696fad1853ae83c71c9716bcf7302b3be49207ff.tar.gz |
gobex: Add debug option to apparam
This adds "apparam" to the debug options of GOBEX_DEBUG
Diffstat (limited to 'gobex/gobex.c')
-rw-r--r-- | gobex/gobex.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/gobex/gobex.c b/gobex/gobex.c index b6126b8d4..7c136af9e 100644 --- a/gobex/gobex.c +++ b/gobex/gobex.c @@ -267,7 +267,7 @@ static gboolean write_stream(GObex *obex, GError **err) if (status != G_IO_STATUS_NORMAL) return FALSE; - g_obex_dump("<", buf, bytes_written); + g_obex_dump(G_OBEX_DEBUG_DATA, "<", buf, bytes_written); obex->tx_sent += bytes_written; obex->tx_data -= bytes_written; @@ -290,7 +290,7 @@ static gboolean write_packet(GObex *obex, GError **err) if (bytes_written != obex->tx_data) return FALSE; - g_obex_dump("<", buf, bytes_written); + g_obex_dump(G_OBEX_DEBUG_DATA, "<", buf, bytes_written); obex->tx_sent += bytes_written; obex->tx_data -= bytes_written; @@ -1078,7 +1078,7 @@ read_body: } while (rbytes > 0 && obex->rx_data < obex->rx_pkt_len); done: - g_obex_dump(">", obex->rx_buf, obex->rx_data); + g_obex_dump(G_OBEX_DEBUG_DATA, ">", obex->rx_buf, obex->rx_data); return TRUE; } @@ -1124,7 +1124,7 @@ static gboolean read_packet(GObex *obex, GError **err) return FALSE; } - g_obex_dump(">", obex->rx_buf, obex->rx_data); + g_obex_dump(G_OBEX_DEBUG_DATA, ">", obex->rx_buf, obex->rx_data); return TRUE; fail: @@ -1236,6 +1236,7 @@ static GDebugKey keys[] = { { "header", G_OBEX_DEBUG_HEADER }, { "packet", G_OBEX_DEBUG_PACKET }, { "data", G_OBEX_DEBUG_DATA }, + { "apparam", G_OBEX_DEBUG_APPARAM }, }; GObex *g_obex_new(GIOChannel *io, GObexTransportType transport_type, @@ -1248,7 +1249,7 @@ GObex *g_obex_new(GIOChannel *io, GObexTransportType transport_type, const char *env = g_getenv("GOBEX_DEBUG"); if (env) { - gobex_debug = g_parse_debug_string(env, keys, 6); + gobex_debug = g_parse_debug_string(env, keys, 7); g_setenv("G_MESSAGES_DEBUG", "gobex", FALSE); } else gobex_debug = G_OBEX_DEBUG_NONE; |