Ignore:
Timestamp:
01/08/19 10:09:47 (22 months ago)
Author:
Shane Alcock <salcock@…>
Branches:
develop
Children:
4ac48fa
Parents:
2bce91d
Message:

Make sure we zero any filter structures we allocate

This fixes "uninitialised bytes" warnings that we get from
valgrind whenever filters are used with ring:

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/format_linux_common.c

    r630460b r5fe998b  
    7373         * deletion causing the filter to no longer work */
    7474        f = (libtrace_filter_t *) malloc(sizeof(libtrace_filter_t));
     75        memset(f, 0, sizeof(libtrace_filter_t));
    7576        memcpy(f, filter, sizeof(libtrace_filter_t));
    7677        f->filterstring = strdup(filter->filterstring);
Note: See TracChangeset for help on using the changeset viewer.