On 09/15/2015 09:51 AM, Richard Haines wrote: > Ensure all memory is freed - checked using valgrind > > Signed-off-by: Richard Haines <richard_c_haines@xxxxxxxxxxxxxx> Thanks, applied. > --- > libselinux/src/label_media.c | 2 +- > libselinux/src/label_x.c | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/libselinux/src/label_media.c b/libselinux/src/label_media.c > index 725d5bd..c589ca3 100644 > --- a/libselinux/src/label_media.c > +++ b/libselinux/src/label_media.c > @@ -161,7 +161,7 @@ static void close(struct selabel_handle *rec) > if (spec_arr) > free(spec_arr); > > - memset(data, 0, sizeof(*data)); > + free(data); > } > > static struct selabel_lookup_rec *lookup(struct selabel_handle *rec, > diff --git a/libselinux/src/label_x.c b/libselinux/src/label_x.c > index 3f2ee1c..3d13b23 100644 > --- a/libselinux/src/label_x.c > +++ b/libselinux/src/label_x.c > @@ -188,7 +188,7 @@ static void close(struct selabel_handle *rec) > if (spec_arr) > free(spec_arr); > > - memset(data, 0, sizeof(*data)); > + free(data); > } > > static struct selabel_lookup_rec *lookup(struct selabel_handle *rec, > _______________________________________________ Selinux mailing list Selinux@xxxxxxxxxxxxx To unsubscribe, send email to Selinux-leave@xxxxxxxxxxxxx. To get help, send an email containing "help" to Selinux-request@xxxxxxxxxxxxx.