shithub: sox

Download patch

ref: beca3a7dde21fe0a09542b49166bc94e954ae8e7
parent: 59bd2c555552dc2c877fb040b31071bbc6c1a166
author: cbagwell <cbagwell>
date: Tue Sep 2 21:23:32 EDT 2008

Remove dead code.

--- a/src/effects.c
+++ b/src/effects.c
@@ -67,8 +67,6 @@
 {
   sox_effect_t * effp = lsx_calloc(1, sizeof(*effp));
 
-  if (!effp) return NULL;
-
   effp->global_info = &sox_effects_globals;
   effp->handler = *eh;
   if (!effp->handler.getopts) effp->handler.getopts = default_getopts;
@@ -79,11 +77,6 @@
   if (!effp->handler.kill   ) effp->handler.kill    = default_function;
 
   effp->priv = lsx_calloc(1, effp->handler.priv_size);
-  if (effp->handler.priv_size && !effp->priv)
-  {
-    free(effp);
-    return NULL;
-  }
 
   return effp;
 } /* sox_create_effect */