Summary: | ASTERISK-04959: [patch] ast_var_assign does not initialize ast_var_t data structure | ||
Reporter: | Di-Shi Sun (homesick) | Labels: | |
Date Opened: | 2005-09-01 10:43:43 | Date Closed: | 2008-01-15 15:46:47.000-0600 |
Priority: | Critical | Regression? | No |
Status: | Closed/Complete | Components: | Core/General |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ( 0) ast_var_assign.patch | |
Description: | ast_var_assign function in asterisk/charvars.c does not initialize the ast_var_t data structure it creates. This fucntion mallocs a memory block for a ast_var_t data structure, and does not initizlized it (in fact, does not initizlize the "next" pointer). It causes that any function reading the "next" pointer uses this pointer as non-NULL, and carsh. It did occur with AST_LIST_INSERT_TAIL. ****** ADDITIONAL INFORMATION ****** Disclaimer signed by TransNexus, Inc. 1/27/05 | ||
Comments: | By: Kevin P. Fleming (kpfleming) 2005-09-01 18:08:06 Committed to CVS HEAD, thanks! By: Digium Subversion (svnbot) 2008-01-15 15:46:47.000-0600 Repository: asterisk Revision: 6494 U trunk/chanvars.c ------------------------------------------------------------------------ r6494 | kpfleming | 2008-01-15 15:46:47 -0600 (Tue, 15 Jan 2008) | 2 lines ensure variable structure is initialized before use (issue ASTERISK-4959) ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=6494 |