Whaddya know, it wouldn't compile

This commit is contained in:
dcp1990 2005-06-12 18:56:20 +00:00
parent ca44312d08
commit d1245a33c0

View file

@ -27,7 +27,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE. * SUCH DAMAGE.
*/ */
/* $Amigan: phoned/phoned/filters.c,v 1.6 2005/06/12 18:53:52 dcp1990 Exp $ */ /* $Amigan: phoned/phoned/filters.c,v 1.7 2005/06/12 18:56:20 dcp1990 Exp $ */
#include <string.h> #include <string.h>
#include <stdlib.h> #include <stdlib.h>
#include <unistd.h> #include <unistd.h>
@ -42,8 +42,8 @@ void free_cond_elms(cond)
{ {
free(cond->name); free(cond->name);
free(cond->number); free(cond->number);
free(cond->filtname); free(cond->filtername);
free(cond->namex.prex); free(cond->namerx.prex);
} }
void free_condition(h, traverse) void free_condition(h, traverse)
cond_t* h; cond_t* h;
@ -55,7 +55,7 @@ void free_condition(h, traverse)
pthread_mutex_lock(&condmx); pthread_mutex_lock(&condmx);
if(traverse) { if(traverse) {
c = tp; c = tp;
while(c > 0x0) { while(c != NULL) {
free_cond_elms(c); free_cond_elms(c);
ls = c; ls = c;
c = c->next; c = c->next;
@ -85,7 +85,7 @@ cond_t* add_condition(filtname, nameregex, numregex, action)
nc->last = c; nc->last = c;
c->next = nc; c->next = nc;
} }
nc->name = strdup(filtname); nc->filtername = strdup(filtname);
if(nameregex != 0x0) { if(nameregex != 0x0) {
nc->name = strdup(nameregex); nc->name = strdup(nameregex);
nc->namerx.prex = pcre_compile(nc->name, 0x0, &nc->namerx.error, nc->namerx.prex = pcre_compile(nc->name, 0x0, &nc->namerx.error,