From: Richard Mudgett Date: Wed, 10 Oct 2012 21:31:35 +0000 (+0000) Subject: Fix compiler warnings. X-Git-Tag: certified/1.8.11-cert8~11 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=681e330c240243c8e7398d2c9d07de6e081567b6;p=thirdparty%2Fasterisk.git Fix compiler warnings. gcc (GCC) 4.2.4 has problems casting away constness. ........ Merged revisions 370275 from http://svn.asterisk.org/svn/asterisk/branches/1.8 git-svn-id: https://origsvn.digium.com/svn/asterisk/certified/branches/1.8.11@374832 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/main/cel.c b/main/cel.c index 4bedc34737..161e490d1e 100644 --- a/main/cel.c +++ b/main/cel.c @@ -507,11 +507,10 @@ struct ast_channel *ast_cel_fabricate_channel_from_event(const struct ast_event return NULL; } - tchan->appl = app_data; - tchan->data = app_data + strlen(record.application_name) + 1; + tchan->appl = strcpy(app_data, record.application_name); + tchan->data = strcpy(app_data + strlen(record.application_name) + 1, + record.application_data); - strcpy((char *) tchan->appl, record.application_name); - strcpy((char *) tchan->data, record.application_data); datastore->data = app_data; ast_channel_datastore_add(tchan, datastore);