diff options
-rw-r--r-- | src/modules/asc/asc.c | 6 | ||||
-rw-r--r-- | src/modules/checkers/checkers.c | 6 | ||||
-rw-r--r-- | src/modules/mixer/mixer.c | 8 | ||||
-rw-r--r-- | src/modules/montage/montage.c | 8 | ||||
-rw-r--r-- | src/modules/rkt/rkt.c | 16 | ||||
-rw-r--r-- | src/modules/roto/roto.c | 6 |
6 files changed, 19 insertions, 31 deletions
diff --git a/src/modules/asc/asc.c b/src/modules/asc/asc.c index e359e62..50f81b3 100644 --- a/src/modules/asc/asc.c +++ b/src/modules/asc/asc.c @@ -167,10 +167,8 @@ static void asc_setup_free(til_setup_t *setup) { asc_setup_t *s = (asc_setup_t *)setup; - if (s) { - free((void *)s->string); - free(s); - } + free((void *)s->string); + free(s); } diff --git a/src/modules/checkers/checkers.c b/src/modules/checkers/checkers.c index 998c5bf..0e11d72 100644 --- a/src/modules/checkers/checkers.c +++ b/src/modules/checkers/checkers.c @@ -515,10 +515,8 @@ static void checkers_setup_free(til_setup_t *setup) { checkers_setup_t *s = (checkers_setup_t *)setup; - if (s) { - til_setup_free(s->fill_module_setup); - free(setup); - } + til_setup_free(s->fill_module_setup); + free(setup); } diff --git a/src/modules/mixer/mixer.c b/src/modules/mixer/mixer.c index d8c1326..cf57d3d 100644 --- a/src/modules/mixer/mixer.c +++ b/src/modules/mixer/mixer.c @@ -318,12 +318,10 @@ static void mixer_setup_free(til_setup_t *setup) { mixer_setup_t *s = (mixer_setup_t *)setup; - if (s) { - for (size_t i = 0; i < nelems(s->inputs); i++) - til_setup_free(s->inputs[i].setup); + for (size_t i = 0; i < nelems(s->inputs); i++) + til_setup_free(s->inputs[i].setup); - free(setup); - } + free(setup); } diff --git a/src/modules/montage/montage.c b/src/modules/montage/montage.c index 8ee8df7..7dba5a6 100644 --- a/src/modules/montage/montage.c +++ b/src/modules/montage/montage.c @@ -216,11 +216,9 @@ static void montage_setup_free(til_setup_t *setup) { montage_setup_t *s = (montage_setup_t *)setup; - if (s) { - for (size_t i = 0; i < s->n_tiles; i++) - til_setup_free(s->tiles[i].setup); - free(setup); - } + for (size_t i = 0; i < s->n_tiles; i++) + til_setup_free(s->tiles[i].setup); + free(setup); } diff --git a/src/modules/rkt/rkt.c b/src/modules/rkt/rkt.c index 2e8e696..8790f53 100644 --- a/src/modules/rkt/rkt.c +++ b/src/modules/rkt/rkt.c @@ -387,15 +387,13 @@ static void rkt_setup_free(til_setup_t *setup) { rkt_setup_t *s = (rkt_setup_t *)setup; - if (s) { - for (size_t i = 0; i < s->n_scenes; i++) - til_setup_free(s->scenes[i].setup); - - free((void *)s->base); - free((void *)s->host); - free((void *)s->scener_address); - free(setup); - } + for (size_t i = 0; i < s->n_scenes; i++) + til_setup_free(s->scenes[i].setup); + + free((void *)s->base); + free((void *)s->host); + free((void *)s->scener_address); + free(setup); } diff --git a/src/modules/roto/roto.c b/src/modules/roto/roto.c index 8d71cba..4d97fa5 100644 --- a/src/modules/roto/roto.c +++ b/src/modules/roto/roto.c @@ -412,10 +412,8 @@ static void roto_setup_free(til_setup_t *setup) { roto_setup_t *s = (roto_setup_t *)setup; - if (s) { - til_setup_free(s->fill_module_setup); - free(setup); - } + til_setup_free(s->fill_module_setup); + free(setup); } |