mirror of
https://github.com/asterisk/asterisk.git
synced 2025-12-12 18:12:33 +00:00
Compare commits
5 Commits
1.2.24-net
...
1.2.25-net
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ef83b5943e | ||
|
|
5162e5d425 | ||
|
|
c247ee8720 | ||
|
|
ca81e571ae | ||
|
|
c357e38925 |
1
.lastclean
Normal file
1
.lastclean
Normal file
@@ -0,0 +1 @@
|
||||
9
|
||||
2
CREDITS
2
CREDITS
@@ -95,7 +95,7 @@ Leif Madsen, Jared Smith and Jim van Meggelen - the Asterisk book
|
||||
available under a Creative Commons License at http://www.asteriskdocs.org
|
||||
|
||||
=== HOLD MUSIC ===
|
||||
Music provided by www.freeplaymusic.com
|
||||
Music provided by www.opsound.org
|
||||
|
||||
=== OTHER SOURCE CODE IN ASTERISK ===
|
||||
|
||||
|
||||
2
LICENSE
2
LICENSE
@@ -32,7 +32,7 @@ GPL'd products (although if you've written a module for Asterisk we
|
||||
would strongly encourage you to make the same exception that we do).
|
||||
|
||||
Specific permission is also granted to link Asterisk with OpenSSL and
|
||||
OpenH323.
|
||||
OpenH323 and distribute the resulting binary files.
|
||||
|
||||
In addition, Asterisk implements two management/control protocols: the
|
||||
Asterisk Manager Interface (AMI) and the Asterisk Gateway Interface
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
About Hold Music
|
||||
================
|
||||
Digium has licensed the music included with
|
||||
the Asterisk distribution From FreePlayMusic
|
||||
for use and distribution with Asterisk. It
|
||||
is licensed ONLY for use as hold music within
|
||||
an Asterisk based PBX.
|
||||
|
||||
22
README.opsound
Normal file
22
README.opsound
Normal file
@@ -0,0 +1,22 @@
|
||||
About Hold Music
|
||||
================
|
||||
These files were obtained from http://opsound.org, where the authors placed them
|
||||
under the Creative Commons Attribution-Share Alike 2.5 license, a copy of which
|
||||
may be found at http://creativecommons.org.
|
||||
|
||||
Credits
|
||||
================
|
||||
macroform-cold_day - Paul Shuler (Macroform)
|
||||
paulshuler@gmail.com - http://macroform.bandcamp.com/
|
||||
|
||||
macroform-robot_dity - Paul Shuler (Macroform)
|
||||
paulshuler@gmail.com - http://macroform.bandcamp.com/
|
||||
|
||||
macroform-the_simplicity - Paul Shuler (Macroform)
|
||||
paulshuler@gmail.com - http://macroform.bandcamp.com/
|
||||
|
||||
manolo_camp-morning_coffee - Manolo Camp
|
||||
beatbastard@gmx.net - http://ccmixter.org/people/ManoloCamp
|
||||
|
||||
reno_project-system - Reno Project
|
||||
renoproject@hotmail.com - http://www.jamendo.com/en/album/23661
|
||||
@@ -72,6 +72,7 @@ static int pgsql_log(struct ast_cdr *cdr)
|
||||
struct tm tm;
|
||||
char sqlcmd[2048] = "", timestr[128];
|
||||
char *pgerror;
|
||||
int pgerr;
|
||||
|
||||
ast_mutex_lock(&pgsql_lock);
|
||||
|
||||
@@ -91,28 +92,32 @@ static int pgsql_log(struct ast_cdr *cdr)
|
||||
|
||||
if (connected) {
|
||||
char *clid=NULL, *dcontext=NULL, *channel=NULL, *dstchannel=NULL, *lastapp=NULL, *lastdata=NULL;
|
||||
char *uniqueid=NULL, *userfield=NULL;
|
||||
char *uniqueid=NULL, *userfield=NULL, *src=NULL, *dst=NULL;
|
||||
|
||||
/* Maximum space needed would be if all characters needed to be escaped, plus a trailing NULL */
|
||||
if ((clid = alloca(strlen(cdr->clid) * 2 + 1)) != NULL)
|
||||
PQescapeString(clid, cdr->clid, strlen(cdr->clid));
|
||||
PQescapeStringConn(conn, clid, cdr->clid, strlen(cdr->clid), &pgerr);
|
||||
if ((dcontext = alloca(strlen(cdr->dcontext) * 2 + 1)) != NULL)
|
||||
PQescapeString(dcontext, cdr->dcontext, strlen(cdr->dcontext));
|
||||
PQescapeStringConn(conn, dcontext, cdr->dcontext, strlen(cdr->dcontext), &pgerr);
|
||||
if ((channel = alloca(strlen(cdr->channel) * 2 + 1)) != NULL)
|
||||
PQescapeString(channel, cdr->channel, strlen(cdr->channel));
|
||||
PQescapeStringConn(conn, channel, cdr->channel, strlen(cdr->channel), &pgerr);
|
||||
if ((dstchannel = alloca(strlen(cdr->dstchannel) * 2 + 1)) != NULL)
|
||||
PQescapeString(dstchannel, cdr->dstchannel, strlen(cdr->dstchannel));
|
||||
PQescapeStringConn(conn, dstchannel, cdr->dstchannel, strlen(cdr->dstchannel), &pgerr);
|
||||
if ((lastapp = alloca(strlen(cdr->lastapp) * 2 + 1)) != NULL)
|
||||
PQescapeString(lastapp, cdr->lastapp, strlen(cdr->lastapp));
|
||||
PQescapeStringConn(conn, lastapp, cdr->lastapp, strlen(cdr->lastapp), &pgerr);
|
||||
if ((lastdata = alloca(strlen(cdr->lastdata) * 2 + 1)) != NULL)
|
||||
PQescapeString(lastdata, cdr->lastdata, strlen(cdr->lastdata));
|
||||
PQescapeStringConn(conn, lastdata, cdr->lastdata, strlen(cdr->lastdata), &pgerr);
|
||||
if ((uniqueid = alloca(strlen(cdr->uniqueid) * 2 + 1)) != NULL)
|
||||
PQescapeString(uniqueid, cdr->uniqueid, strlen(cdr->uniqueid));
|
||||
PQescapeStringConn(conn, uniqueid, cdr->uniqueid, strlen(cdr->uniqueid), &pgerr);
|
||||
if ((userfield = alloca(strlen(cdr->userfield) * 2 + 1)) != NULL)
|
||||
PQescapeString(userfield, cdr->userfield, strlen(cdr->userfield));
|
||||
PQescapeStringConn(conn, userfield, cdr->userfield, strlen(cdr->userfield), &pgerr);
|
||||
if ((src = alloca(strlen(cdr->src) * 2 + 1)) != NULL)
|
||||
PQescapeStringConn(conn, src, cdr->src, strlen(cdr->src), &pgerr);
|
||||
if ((dst = alloca(strlen(cdr->dst) * 2 + 1)) != NULL)
|
||||
PQescapeStringConn(conn, dst, cdr->dst, strlen(cdr->dst), &pgerr);
|
||||
|
||||
/* Check for all alloca failures above at once */
|
||||
if ((!clid) || (!dcontext) || (!channel) || (!dstchannel) || (!lastapp) || (!lastdata) || (!uniqueid) || (!userfield)) {
|
||||
if ((!clid) || (!dcontext) || (!channel) || (!dstchannel) || (!lastapp) || (!lastdata) || (!uniqueid) || (!userfield) || (!src) || (!dst)) {
|
||||
ast_log(LOG_ERROR, "cdr_pgsql: Out of memory error (insert fails)\n");
|
||||
ast_mutex_unlock(&pgsql_lock);
|
||||
return -1;
|
||||
@@ -123,7 +128,7 @@ static int pgsql_log(struct ast_cdr *cdr)
|
||||
snprintf(sqlcmd,sizeof(sqlcmd),"INSERT INTO %s (calldate,clid,src,dst,dcontext,channel,dstchannel,"
|
||||
"lastapp,lastdata,duration,billsec,disposition,amaflags,accountcode,uniqueid,userfield) VALUES"
|
||||
" ('%s','%s','%s','%s','%s', '%s','%s','%s','%s',%ld,%ld,'%s',%ld,'%s','%s','%s')",
|
||||
table,timestr,clid,cdr->src, cdr->dst, dcontext,channel, dstchannel, lastapp, lastdata,
|
||||
table, timestr, clid, src, dst, dcontext,channel, dstchannel, lastapp, lastdata,
|
||||
cdr->duration,cdr->billsec,ast_cdr_disp2str(cdr->disposition),cdr->amaflags, cdr->accountcode, uniqueid, userfield);
|
||||
|
||||
ast_log(LOG_DEBUG,"cdr_pgsql: SQL command executed: %s\n",sqlcmd);
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
Music Provided By www.freeplaymusic.com. These sound files are provided by
|
||||
Digium under license from Freeplay Music Corporation for use in conjunction
|
||||
with the Asterisk software only.
|
||||
About Hold Music
|
||||
================
|
||||
These files were obtained from http://opsound.org, where the authors placed them
|
||||
under the Creative Commons Attribution-Share Alike 2.5 license, a copy of which
|
||||
may be found at http://creativecommons.org.
|
||||
|
||||
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
sounds/moh/macroform-cold_day.mp3
Normal file
BIN
sounds/moh/macroform-cold_day.mp3
Normal file
Binary file not shown.
BIN
sounds/moh/macroform-robot_dity.mp3
Normal file
BIN
sounds/moh/macroform-robot_dity.mp3
Normal file
Binary file not shown.
BIN
sounds/moh/macroform-the_simplicity.mp3
Normal file
BIN
sounds/moh/macroform-the_simplicity.mp3
Normal file
Binary file not shown.
BIN
sounds/moh/manolo_camp-morning_coffee.mp3
Normal file
BIN
sounds/moh/manolo_camp-morning_coffee.mp3
Normal file
Binary file not shown.
BIN
sounds/moh/reno_project-system.mp3
Normal file
BIN
sounds/moh/reno_project-system.mp3
Normal file
Binary file not shown.
Reference in New Issue
Block a user