[Oisf-devel] [COMMIT] OISF branch, master, updated. suricata-2.0beta1-2-g9f3e2f7

noreply at openinfosecfoundation.org noreply at openinfosecfoundation.org
Fri Jul 19 10:58:36 UTC 2013


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 "OISF".

The branch, master has been updated
       via  9f3e2f7a927d19ba69db8ddaa10aedbc78274c91 (commit)
       via  b076a26cdc029a54b7f0fdec30b9bb508424a79e (commit)
      from  f09f289b348ce1c5eff7be7cf343646bb9ff6c33 (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 -----------------------------------------------------------------
commit 9f3e2f7a927d19ba69db8ddaa10aedbc78274c91
Author: Victor Julien <victor at inliniac.net>
Date:   Fri Jul 19 12:33:34 2013 +0200

    NFQ: adapt to ReleasePacket API

commit b076a26cdc029a54b7f0fdec30b9bb508424a79e
Author: Ken Steele <ken at tilera.com>
Date:   Wed Jul 10 16:47:52 2013 -0400

    Replace ReleaseData function on Packet Structure with ReleasePacket.
    
    This commit allows handling Packets allocated by different methods.
    The ReleaseData function pointer in the Packet structure is replaced
    with ReleasePacket function pointer, which is then always called to
    release the memory associated with a Packet.
    
    Currently, the only usage of ReleaseData is in AF Packet. Previously
    ReleaseData was only called when it was not NULL. To implement the
    same functionality as before in AF Packet, a new function is defined
    in AF Packet to first call the AFP specific ReleaseData function and
    then releases the Packet structure.
    
    Three new general functions are defined for releasing packets in the
    default case:
        1) PacketFree() - To release a packet alloced with SCMalloc()
        2) PacketPoolReturnPacket() - For packets allocated from the Packet Pool.
                                      Calls RECYCLE_PACKET(p)
        3) PacketFreeOrRelease() - Calls PacketFree() or PacketPoolReturnPacket()
                                     based on the PKT_ALLOC flag.
    
    Having these functions removes the need to check the PKT_ALLOC flag
    when releasing a packet in most cases, since the ReleasePacket
    function encodes how the Packet was allocated. The PKT_ALLOC flag is
    still set and is needed when AF Packet releases a packet, since it
    replaces the ReleasePacket function pointer with its own function and
    then calls PacketFreeOfRelease(), which uses the PKT_ALLOC flag.

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

Summary of changes:
 src/decode.c           |   39 +++++++++++++++++++++++++++++++--------
 src/decode.h           |    7 ++++---
 src/source-af-packet.c |   16 ++++++++++------
 src/source-nfq.c       |    5 ++---
 src/tmqh-packetpool.c  |   44 ++++++++++++++------------------------------
 src/tmqh-packetpool.h  |    4 ++--
 6 files changed, 63 insertions(+), 52 deletions(-)


hooks/post-receive
-- 
OISF


More information about the Oisf-devel mailing list