--- compat/pand.c | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/compat/pand.c b/compat/pand.c index c3860fa..b82650e 100644 --- a/compat/pand.c +++ b/compat/pand.c @@ -456,10 +456,13 @@ static void do_show(void) static void do_kill(char *dst) { - if (dst) - bnep_kill_connection((void *) strtoba(dst)); - else + if (dst) { + bdaddr_t *ba = strtoba(dst); + bnep_kill_connection((void *) ba); + free(ba); + } else { bnep_kill_all_connections(); + } } static void sig_hup(int sig) -- 1.7.0.4 on behalf of ST-Ericsson -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html