[asterisk-commits] oej: branch oej/pinequeue-1.8 r363094 - in /team/oej/pinequeue-1.8: apps/ inc...
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon Apr 23 06:08:44 CDT 2012
Author: oej
Date: Mon Apr 23 06:08:40 2012
New Revision: 363094
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=363094
Log:
Make life easier for me and gcc
Modified:
team/oej/pinequeue-1.8/apps/app_queue.c
team/oej/pinequeue-1.8/include/asterisk/file.h
team/oej/pinequeue-1.8/main/file.c
team/oej/pinequeue-1.8/main/say.c
Modified: team/oej/pinequeue-1.8/apps/app_queue.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/pinequeue-1.8/apps/app_queue.c?view=diff&rev=363094&r1=363093&r2=363094
==============================================================================
--- team/oej/pinequeue-1.8/apps/app_queue.c (original)
+++ team/oej/pinequeue-1.8/apps/app_queue.c Mon Apr 23 06:08:40 2012
@@ -881,7 +881,6 @@
{ QUEUE_AUTOPAUSE_ALL,"all" },
};
-
static struct ast_taskprocessor *devicestate_tps;
#define DEFAULT_RETRY 5
@@ -2527,7 +2526,6 @@
return res;
}
-extern const struct ast_datastore_info queue_ds_sound_ending;
void destroy_streamfile_info(struct ast_queue_streamfile_info *playdata);
/* Uncommented by Old Olle patch
static int play_file(struct ast_channel *chan, const char *filename)
@@ -5982,7 +5980,7 @@
}
/* look up the datastore and the play_finished struct, and set appropriate values */
- if ((datastore = ast_channel_datastore_find(chan, &queue_ds_sound_ending, NULL))) {
+ if ((datastore = ast_channel_datastore_find(chan, queue_ds_sound_ending(), NULL))) {
aqsi = datastore->data;
if (aqsi) { /* copy this stuff into place */
aqsi->ringing = ringing;
@@ -6256,7 +6254,7 @@
S_COR(chan->caller.id.number.valid, chan->caller.id.number.str, ""),
qe.opos);
/* Begin old Olle patch */
- datastore = ast_channel_datastore_alloc(&queue_ds_sound_ending, NULL);
+ datastore = ast_datastore_alloc(queue_ds_sound_ending(), NULL);
aqsi->qe = &qe;
aqsi->chan = chan;
Modified: team/oej/pinequeue-1.8/include/asterisk/file.h
URL: http://svnview.digium.com/svn/asterisk/team/oej/pinequeue-1.8/include/asterisk/file.h?view=diff&rev=363094&r1=363093&r2=363094
==============================================================================
--- team/oej/pinequeue-1.8/include/asterisk/file.h (original)
+++ team/oej/pinequeue-1.8/include/asterisk/file.h Mon Apr 23 06:08:40 2012
@@ -39,6 +39,8 @@
struct ast_filestream;
struct ast_format;
+
+const struct ast_datastore_info *queue_ds_sound_ending(void);
/*! The maximum number of formats we expect to see in a format string */
#define AST_MAX_FORMATS 10
@@ -336,6 +338,7 @@
*/
char *ast_format_str_reduce(char *fmts);
+
#if defined(__cplusplus) || defined(c_plusplus)
}
#endif
Modified: team/oej/pinequeue-1.8/main/file.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/pinequeue-1.8/main/file.c?view=diff&rev=363094&r1=363093&r2=363094
==============================================================================
--- team/oej/pinequeue-1.8/main/file.c (original)
+++ team/oej/pinequeue-1.8/main/file.c Mon Apr 23 06:08:40 2012
@@ -709,11 +709,17 @@
return NULL;
}
-const struct ast_datastore_info queue_ds_sound_ending = { /* this is here because it is referenced here
+const struct ast_datastore_info queue_ds_sound_ending_obj = { /* this is here because it is referenced here
and the only other place it is used is in app_queue,
which is not always loaded. */
.type = "queue_sound_ending"
};
+
+const struct ast_datastore_info *queue_ds_sound_ending()
+{
+ return &queue_ds_sound_ending_obj;
+}
+
static struct ast_frame *read_frame(struct ast_filestream *s, int *whennext)
{
Modified: team/oej/pinequeue-1.8/main/say.c
URL: http://svnview.digium.com/svn/asterisk/team/oej/pinequeue-1.8/main/say.c?view=diff&rev=363094&r1=363093&r2=363094
==============================================================================
--- team/oej/pinequeue-1.8/main/say.c (original)
+++ team/oej/pinequeue-1.8/main/say.c Mon Apr 23 06:08:40 2012
@@ -410,12 +410,11 @@
{
int res;
struct ast_datastore *datastore;
- extern const struct ast_datastore_info queue_ds_sound_ending; /* defined in file.c */
/* if a datastore is present, we are in the queue app (perhaps others in time)
and don't want to wait around for the sounds to finish playing */
- if ((datastore = ast_channel_datastore_find(chan, &queue_ds_sound_ending, NULL))) { /* app_queue wants to schedule this instead of play & wait */
+ if ((datastore = ast_channel_datastore_find(chan, queue_ds_sound_ending(), NULL))) { /* app_queue wants to schedule this instead of play & wait */
struct ast_queue_streamfile_info *aqsi = datastore->data;
if (aqsi) {
AST_LIST_LOCK(&aqsi->flist);
More information about the asterisk-commits
mailing list