conversions to use allocation wrappers (issue #6277)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@8381 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Russell Bryant
2006-01-21 08:45:39 +00:00
parent 2499926195
commit fbdc8ce317
10 changed files with 55 additions and 58 deletions

View File

@@ -44,6 +44,7 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
#include "asterisk/module.h"
#include "asterisk/logger.h"
#include "asterisk/channel.h"
#include "asterisk/utils.h"
#ifdef USE_EXTERNAL_GSM_LIB
#include <gsm/gsm.h>
@@ -81,9 +82,8 @@ struct ast_translator_pvt {
static struct ast_translator_pvt *gsm_new(void)
{
struct gsm_coder_pvt *tmp;
tmp = malloc(sizeof(struct gsm_coder_pvt));
if (tmp) {
struct gsm_coder_pvt *tmp;
if ((tmp = ast_malloc(sizeof(*tmp)))) {
if (!(tmp->gsm = gsm_create())) {
free(tmp);
tmp = NULL;