List improvements from kpfleming (bugs #3166,#3140)
[asterisk/asterisk.git] / channel.c
index fb3edd3..307e95a 100755 (executable)
--- a/channel.c
+++ b/channel.c
@@ -673,7 +673,7 @@ void ast_channel_free(struct ast_channel *chan)
        /* no need to lock the list, as the channel is already locked */
        
        while (!AST_LIST_EMPTY(headp)) {           /* List Deletion. */
-                   vardata = AST_LIST_REMOVE_HEAD(headp, ast_var_t, entries);
+                   vardata = AST_LIST_REMOVE_HEAD(headp, entries);
 /*                 printf("deleting var %s=%s\n",ast_var_name(vardata),ast_var_value(vardata)); */
                    ast_var_delete(vardata);
        }