Subject: libosmo-netif.git branch master updated. 0.0.2-21-g87b3eea
From: [email-masked]
To: [email-masked]
Date: Fri, 13 Dec 2013 14:23:14 GMT

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Osmocom network interface library".

The branch, master has been updated
       via  87b3eeaed7dfd321e1964d44019d4c7e6ae88f48 (commit)
      from  9b1c0804d967a0d32217503756a67be84b6e6d17 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cgit.osmocom.org/libosmo-netif/commit/?id=87b3eeaed7dfd321e1964d44019d4c7e6ae88f48

commit 87b3eeaed7dfd321e1964d44019d4c7e6ae88f48
Author: Pablo Neira Ayuso <[email-masked]>
Date:   Fri Dec 13 15:18:56 2013 +0100

    osmux: delete message from output list before calling tx_cb
    
    Valgrind complains about a possible use after free:
    
    ==12800== Invalid read of size 4
    ==12800==    at 0x4073DF6: osmux_tx_sched (linuxlist.h:119)
    ==12800==    by 0x8052B0F: osmux_read_from_bsc_nat_cb (osmux.c:261)
    ==12800==    by 0x453F967: ???
    ==12800==  Address 0x453f710 is 48 bytes inside a block of size 145
    +free'd
    ==12800==    at 0x402750C: free (vg_replace_malloc.c:427)
    ==12800==    by 0x4064ADE: talloc_free (talloc.c:609)
    ==12800==    by 0x405AAAA: msgb_free (msgb.c:72)
    ==12800==    by 0x8052492: scheduled_tx_bts_cb (osmux.c:196)
    ==12800==    by 0x4072CF8: osmux_tx_cb (osmux.c:554)
    ==12800==    by 0x4073F03: osmux_tx_sched (osmux.c:582)
    ==12800==    by 0x8052B0F: osmux_read_from_bsc_nat_cb (osmux.c:261)
    ==12800==    by 0x453F967: ???
    
    The problem is that osmux_tx_sched may immediately call osmux_tx_cb for
    the first extracted RTP message from the osmux batch, which releases the
    message after that.
    
    Remove the message from our list of messages to be transmitted before
    the message is passed to the tx callback.
    
    Reported by Mattias Lundstrom.

-----------------------------------------------------------------------

Summary of changes:
 src/osmux.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

hooks/post-receive
-- 
Osmocom network interface library