[Oisf-devel] [COMMIT] OISF branch, master, updated. suricata-2.0beta1-496-g1cce207

noreply at openinfosecfoundation.org noreply at openinfosecfoundation.org
Fri Dec 13 15:36:52 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  1cce207c0502c4122282db366c54ed95bbd342b2 (commit)
       via  9874c1a83b511338ee9b9825327d92d754d06d3b (commit)
       via  1fbaebad63c10ade0d5d445dac12104d10303488 (commit)
       via  1f07d1521ebf5ac0a46490c3c614e49546fc2d51 (commit)
       via  5e1f1ee4ffd4987d83e474757dda0f638e1a8897 (commit)
       via  d12834769a32b410543a1c2202274177499b56ef (commit)
       via  8ba0fa7f92d01361baa1d3ed7c62d7a5a0c52b67 (commit)
       via  de22d6cf02408003b42e2fad7604c8af6fe12f4d (commit)
      from  2913a4a86084441a2e9504bcd32a373f15aa65a9 (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 1cce207c0502c4122282db366c54ed95bbd342b2
Author: Victor Julien <victor at inliniac.net>
Date:   Fri Dec 13 12:50:43 2013 +0100

    Revert TmqhFlowMode alignment as it breaks on CLANG

commit 9874c1a83b511338ee9b9825327d92d754d06d3b
Author: Victor Julien <victor at inliniac.net>
Date:   Fri Dec 13 12:20:00 2013 +0100

    realloc error handling: remove unnecessary else branch

commit 1fbaebad63c10ade0d5d445dac12104d10303488
Author: Eric Leblond <eric at regit.org>
Date:   Thu Dec 12 13:34:54 2013 +0100

    coccinelle: add test on realloc
    
    If we use SCRealloc like:
     x = SCRealloc(x, ...)
    then in case of failure we are loosing the original pointer value
    and the memory is lost and can not be free.
    
    This test just check for this construction and output an error if
    it finds it.

commit 1f07d1521ebf5ac0a46490c3c614e49546fc2d51
Author: Eric Leblond <eric at regit.org>
Date:   Thu Dec 12 13:10:01 2013 +0100

    Fix realloc error handling
    
    This patch is fixing realloc error handling. In case of a realloc
    failure, it free the initial memory and continue existing error
    handling.
    
    The patch has been obtained via the following semantic patch and
    a bit oh hand editing:
    
    @@
    expression x, E;
    identifier f;
    @@
    
    f(...)
    {
    + void *ptmp;
    <+...
    - x = SCRealloc(x, E);
    + ptmp = SCRealloc(x, E);
    ... when != x
    - if (x == NULL)
    + if (ptmp == NULL)
    {
    + SCFree(x);
    + x = NULL;
    ...
    - }
    + } else {
    +     x = ptmp;
    + }
    ...+>
    }
    
    @@
    expression x, E;
    identifier f;
    statement ES;
    @@
    
    f(...) {
    + void *ptmp;
    
    <+...
    - x = SCRealloc(x, E);
    + ptmp = SCRealloc(x, E);
    ... when != x
    - if (x == NULL) ES
    + if (ptmp == NULL) {
    + SCFree(x);
    + x = NULL;
    + ES
    + } else {
    +     x = ptmp;
    + }
    ...+>
    
    }
    
    @@
    expression x, E;
    identifier f;
    @@
    
    f(...)
    {
    + void *ptmp;
    <+...
    - x = SCRealloc(x, E);
    + ptmp = SCRealloc(x, E);
    ... when != x
    - if (unlikely(x == NULL))
    + if (unlikely(ptmp == NULL))
    {
    + SCFree(x);
    + x = NULL;
    ...
    - }
    + } else {
    +     x = ptmp;
    + }
    ...+>
    }
    
    @@
    expression x, E;
    identifier f;
    statement ES;
    @@
    
    f(...) {
    + void *ptmp;
    
    <+...
    - x = SCRealloc(x, E);
    + ptmp = SCRealloc(x, E);
    ... when != x
    - if (unlikely(x == NULL)) ES
    + if (unlikely(ptmp == NULL)) {
    + SCFree(x);
    + x = NULL;
    + ES
    + } else {
    +     x = ptmp;
    + }
    ...+>
    
    }

commit 5e1f1ee4ffd4987d83e474757dda0f638e1a8897
Author: Victor Julien <victor at inliniac.net>
Date:   Thu Dec 12 17:01:49 2013 +0100

    Fix filemagic unittests on OS_DARWIN

commit d12834769a32b410543a1c2202274177499b56ef
Author: Ken Steele <ken at tilera.com>
Date:   Sat Nov 16 11:13:42 2013 -0500

    Add const for Packet * in flow functions.
    
    By moving FlowReference() out of FlowGetFlowFromHash() and into the one
    function that calls it, all the flow functions take const Packet * instead
    of Packet *.

commit 8ba0fa7f92d01361baa1d3ed7c62d7a5a0c52b67
Author: Giuseppe Longo <giuseppelng at gmail.com>
Date:   Thu Dec 12 23:03:42 2013 +0100

    defrag-config: fix a bug
    
    A ptr to local var is stored in the radix tree currently,
    this patch permits to alloc space to store host timeout
    and thus also free it when data is removed.

commit de22d6cf02408003b42e2fad7604c8af6fe12f4d
Author: Victor Julien <victor at inliniac.net>
Date:   Thu Dec 12 19:28:22 2013 +0100

    defrag: fix compiler warning
    
    defrag-config.c: In function 'DefragParseParameters':
    defrag-config.c:105: warning: passing argument 2 of 'DefragPolicyAddHostInfo' from incompatible pointer type
    make[3]: *** [defrag-config.o] Error 1

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

Summary of changes:
 qa/coccinelle/realloc.cocci  |   18 ++++++++++++
 src/app-layer-dcerpc-udp.c   |    9 +++++-
 src/app-layer-dcerpc.c       |    9 +++++-
 src/app-layer-ftp.c          |   35 ++++++++++++++++-------
 src/app-layer-htp.c          |   34 +++++++++++++++++-----
 src/app-layer-parser.c       |   62 +++++++++++++++++++++++++++++++----------
 src/app-layer-smtp.c         |   62 ++++++++++++++++++++++++++++-------------
 src/app-layer-ssl.c          |    9 +++++-
 src/counters.c               |   11 +++++--
 src/defrag-config.c          |   27 ++++++++++++++----
 src/detect-engine-hcbd.c     |   16 +++++++++--
 src/detect-engine-hhd.c      |   19 ++++++++++---
 src/detect-engine-hsbd.c     |   16 +++++++++--
 src/detect-engine-siggroup.c |   11 ++++++-
 src/flow-hash.c              |   25 +++++------------
 src/flow-hash.h              |    2 +-
 src/flow-util.c              |    2 +-
 src/flow-util.h              |    2 +-
 src/flow.c                   |   11 +++++---
 src/flow.h                   |    2 +-
 src/log-tlslog.c             |    8 ++++-
 src/runmodes.c               |   11 +++++---
 src/tmqh-flow.c              |    9 +++++-
 src/tmqh-flow.h              |    6 +---
 src/util-cuda-handlers.c     |   10 +++++-
 src/util-magic.c             |    6 ++--
 src/util-mpm-ac-bs.c         |   41 ++++++++++++++++++++-------
 src/util-mpm-ac-gfbs.c       |   39 +++++++++++++++++++-------
 src/util-mpm-ac-tile.c       |   39 +++++++++++++++++++-------
 src/util-mpm-ac.c            |   39 +++++++++++++++++++-------
 src/util-mpm.c               |   10 +++++--
 src/util-pool-thread.c       |    9 +++++-
 src/util-radix-tree.c        |   37 +++++++++++++++++++-----
 src/util-threshold-config.c  |   22 +++++++++++----
 34 files changed, 481 insertions(+), 187 deletions(-)
 create mode 100644 qa/coccinelle/realloc.cocci


hooks/post-receive
-- 
OISF


More information about the Oisf-devel mailing list