another round of version tag updates, along with 'show version files' pattern filtering
authorKevin P. Fleming <kpfleming@digium.com>
Mon, 6 Jun 2005 21:09:59 +0000 (21:09 +0000)
committerKevin P. Fleming <kpfleming@digium.com>
Mon, 6 Jun 2005 21:09:59 +0000 (21:09 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@5865 65c4cc65-6c06-0410-ace0-fbb531ad65f3

28 files changed:
asterisk.c
cdr/cdr_csv.c
cdr/cdr_custom.c
cdr/cdr_manager.c
cdr/cdr_odbc.c
cdr/cdr_pgsql.c
cdr/cdr_sqlite.c
cdr/cdr_tds.c
channels/chan_agent.c
channels/chan_alsa.c
channels/chan_features.c
channels/chan_h323.c
channels/chan_iax2.c
channels/chan_local.c
channels/chan_mgcp.c
channels/chan_modem.c
channels/chan_modem_aopen.c
channels/chan_modem_bestdata.c
channels/chan_modem_i4l.c
channels/chan_nbs.c
channels/chan_oss.c
channels/chan_phone.c
channels/chan_sip.c
channels/chan_skinny.c
channels/chan_vpb.c
channels/chan_zap.c
channels/iax2-parser.c
channels/iax2-provision.c

index 91db7d9..00a1b50 100755 (executable)
@@ -153,9 +153,9 @@ static int restartnow = 0;
 static pthread_t consolethread = AST_PTHREADT_NULL;
 
 struct file_version {
-       const char *file;
-       const char *version;
        AST_LIST_ENTRY(file_version) list;
+       const char *file;
+       char *version;
 };
 
 static AST_LIST_HEAD_STATIC(file_versions, file_version);
@@ -163,13 +163,20 @@ static AST_LIST_HEAD_STATIC(file_versions, file_version);
 void ast_register_file_version(const char *file, const char *version)
 {
        struct file_version *new;
+       char *work;
+       size_t version_length;
 
-       new = calloc(1, sizeof(*new));
+       work = ast_strdupa(version);
+       work = ast_strip(ast_strip_quoted(work, "$", "$"));
+       version_length = strlen(work) + 1;
+
+       new = calloc(1, sizeof(*new) + version_length);
        if (!new)
                return;
 
        new->file = file;
-       new->version = version;
+       new->version = (char *) new + sizeof(*new);
+       memcpy(new->version, work, version_length);
        AST_LIST_LOCK(&file_versions);
        AST_LIST_INSERT_HEAD(&file_versions, new, list);
        AST_LIST_UNLOCK(&file_versions);
@@ -188,6 +195,8 @@ void ast_unregister_file_version(const char *file)
        }
        AST_LIST_TRAVERSE_SAFE_END;
        AST_LIST_UNLOCK(&file_versions);
+       if (find)
+               free(find);
 }
 
 static char show_version_files_help[] = 
@@ -197,14 +206,42 @@ static char show_version_files_help[] =
 
 static int handle_show_version_files(int fd, int argc, char *argv[])
 {
+#define FORMAT "%-25.25s %-20.20s\n"
        struct file_version *iterator;
+       regex_t regexbuf;
+       int havepattern = 0;
+
+       switch (argc) {
+       case 5:
+               if (!strcasecmp(argv[3], "like")) {
+                       if (regcomp(&regexbuf, argv[4], REG_EXTENDED | REG_NOSUB))
+                               return RESULT_SHOWUSAGE;
+                       havepattern = 1;
+               } else
+                       return RESULT_SHOWUSAGE;
+               break;
+       case 3:
+               break;
+       default:
+               return RESULT_SHOWUSAGE;
+       }
 
+       ast_cli(fd, FORMAT, "File", "Revision");
+       ast_cli(fd, FORMAT, "----", "--------");
        AST_LIST_LOCK(&file_versions);
        AST_LIST_TRAVERSE(&file_versions, iterator, list) {
-               ast_cli(fd, "%-25.25s %-20.20s\n", iterator->file, iterator->version);
+               if (havepattern && regexec(&regexbuf, iterator->file, 0, NULL, 0))
+                       continue;
+
+               ast_cli(fd, FORMAT, iterator->file, iterator->version);
        }
        AST_LIST_UNLOCK(&file_versions);
+
+       if (havepattern)
+               regfree(&regexbuf);
+
        return RESULT_SUCCESS;
+#undef FORMAT
 }
 
 static char *complete_show_version_files(char *line, char *word, int pos, int state)
index aa95fa1..ec995a6 100755 (executable)
  */
 
 #include <sys/types.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/channel.h"
 #include "asterisk/cdr.h"
 #include "asterisk/module.h"
 #include "asterisk/logger.h"
 #include "asterisk/utils.h"
-#include "asterisk.h"
 
 #define CSV_LOG_DIR "/cdr-csv"
 #define CSV_MASTER  "/Master.csv"
index cbb6d97..e524d71 100755 (executable)
  */
 
 #include <sys/types.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/channel.h"
 #include "asterisk/cdr.h"
 #include "asterisk/module.h"
@@ -22,7 +27,6 @@
 #include "asterisk/pbx.h"
 #include "asterisk/logger.h"
 #include "asterisk/utils.h"
-#include "asterisk.h"
 
 #define CUSTOM_LOG_DIR "/cdr_custom"
 
index 5563582..c529d05 100755 (executable)
@@ -9,6 +9,14 @@
  */
 
 #include <sys/types.h>
+#include <strings.h>
+#include <unistd.h>
+#include <time.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/channel.h"
 #include "asterisk/cdr.h"
 #include "asterisk/module.h"
 #include "asterisk/utils.h"
 #include "asterisk/manager.h"
 #include "asterisk/config.h"
-#include "asterisk.h"
-#include <strings.h>
-#include <unistd.h>
-#include <time.h>
 
 #define DATE_FORMAT    "%Y-%m-%d %T"
 #define CONF_FILE      "cdr_manager.conf"
index b654f6b..feed26a 100755 (executable)
  */
 
 #include <sys/types.h>
-#include "asterisk/config.h"
-#include "asterisk/options.h"
-#include "asterisk/channel.h"
-#include "asterisk/cdr.h"
-#include "asterisk/module.h"
-#include "asterisk/logger.h"
-#include "asterisk.h"
-
 #include <stdio.h>
 #include <string.h>
 
 #include <sqlext.h>
 #include <sqltypes.h>
 
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/config.h"
+#include "asterisk/options.h"
+#include "asterisk/channel.h"
+#include "asterisk/cdr.h"
+#include "asterisk/module.h"
+#include "asterisk/logger.h"
+
 #define DATE_FORMAT "%Y-%m-%d %T"
 
 static char *desc = "ODBC CDR Backend";
index 2cff8f3..7039e72 100755 (executable)
  */
 
 #include <sys/types.h>
-#include "asterisk/config.h"
-#include "asterisk/options.h"
-#include "asterisk/channel.h"
-#include "asterisk/cdr.h"
-#include "asterisk/module.h"
-#include "asterisk/logger.h"
-#include "asterisk.h"
-
 #include <stdio.h>
 #include <string.h>
 
 
 #include <libpq-fe.h>
 
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/config.h"
+#include "asterisk/options.h"
+#include "asterisk/channel.h"
+#include "asterisk/cdr.h"
+#include "asterisk/module.h"
+#include "asterisk/logger.h"
+#include "asterisk.h"
+
 #define DATE_FORMAT "%Y-%m-%d %T"
 
 static char *desc = "PostgreSQL CDR Backend";
index ec6018c..acadb32 100755 (executable)
  */
 
 #include <sys/types.h>
-#include "asterisk/channel.h"
-#include "asterisk/module.h"
-#include "asterisk/logger.h"
-#include "asterisk/utils.h"
-#include "asterisk.h"
-#include "astconf.h"
 
 #include <unistd.h>
 #include <string.h>
 #include <stdlib.h>
 #include <sqlite.h>
 
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/channel.h"
+#include "asterisk/module.h"
+#include "asterisk/logger.h"
+#include "asterisk/utils.h"
 
 #define LOG_UNIQUEID   0
 #define LOG_USERFIELD  0
index 59076a2..0887b8f 100755 (executable)
@@ -35,14 +35,6 @@ CREATE TABLE [dbo].[cdr] (
 */
 
 #include <sys/types.h>
-#include "asterisk/config.h"
-#include "asterisk/options.h"
-#include "asterisk/channel.h"
-#include "asterisk/cdr.h"
-#include "asterisk/module.h"
-#include "asterisk/logger.h"
-#include "asterisk.h"
-
 #include <stdio.h>
 #include <string.h>
 #include <stdlib.h>
@@ -54,6 +46,17 @@ CREATE TABLE [dbo].[cdr] (
 #include <tdsconvert.h>
 #include <ctype.h>
 
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/config.h"
+#include "asterisk/options.h"
+#include "asterisk/channel.h"
+#include "asterisk/cdr.h"
+#include "asterisk/module.h"
+#include "asterisk/logger.h"
+
 #if !defined(TDS_INT_EXIT) 
 #define TDS_PRE_0_62
 #warning "You have older TDS, you should upgrade!"
index f537cf4..102afb0 100755 (executable)
 
 #include <stdio.h>
 #include <string.h>
+#include <sys/socket.h>
+#include <errno.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <fcntl.h>
+#include <netdb.h>
+#include <arpa/inet.h>
+#include <sys/signal.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/channel.h"
 #include "asterisk/config.h"
 #include "asterisk/utils.h"
 #include "asterisk/causes.h"
 #include "asterisk/astdb.h"
-#include <sys/socket.h>
-#include <errno.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <fcntl.h>
-#include <netdb.h>
-#include <arpa/inet.h>
-#include <sys/signal.h>
 
 static const char desc[] = "Agent Proxy Channel";
 static const char channeltype[] = "Agent";
index 215a55e..9f83429 100755 (executable)
@@ -9,17 +9,6 @@
  * the GNU General Public License
  */
 
-#include "asterisk/frame.h"
-#include "asterisk/logger.h"
-#include "asterisk/channel.h"
-#include "asterisk/module.h"
-#include "asterisk/options.h"
-#include "asterisk/pbx.h"
-#include "asterisk/config.h"
-#include "asterisk/cli.h"
-#include "asterisk/utils.h"
-#include "asterisk/causes.h"
-#include "asterisk/endian.h"
 #include <unistd.h>
 #include <fcntl.h>
 #include <errno.h>
 #define ALSA_PCM_NEW_SW_PARAMS_API
 #include <alsa/asoundlib.h>
 
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/frame.h"
+#include "asterisk/logger.h"
+#include "asterisk/channel.h"
+#include "asterisk/module.h"
+#include "asterisk/options.h"
+#include "asterisk/pbx.h"
+#include "asterisk/config.h"
+#include "asterisk/cli.h"
+#include "asterisk/utils.h"
+#include "asterisk/causes.h"
+#include "asterisk/endian.h"
+
 #include "busy.h"
 #include "ringtone.h"
 #include "ring10.h"
index 6a852bc..03bdba7 100755 (executable)
 
 #include <stdio.h>
 #include <string.h>
+#include <sys/socket.h>
+#include <errno.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <fcntl.h>
+#include <netdb.h>
+#include <arpa/inet.h>
+#include <sys/signal.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/channel.h"
 #include "asterisk/config.h"
 #include "asterisk/app.h"
 #include "asterisk/musiconhold.h"
 #include "asterisk/manager.h"
-#include <sys/socket.h>
-#include <errno.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <fcntl.h>
-#include <netdb.h>
-#include <arpa/inet.h>
-#include <sys/signal.h>
-
 
 static const char desc[] = "Feature Proxy Channel";
 static const char type[] = "Feature";
index f6c9cd5..a449098 100755 (executable)
 #ifdef __cplusplus
 extern "C" {
 #endif   
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/logger.h"
 #include "asterisk/channel.h"
index bd64da6..abb9ef2 100755 (executable)
  * the GNU General Public License
  */
 
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/frame.h" 
 #include "asterisk/channel.h"
index bc177f6..e2e54f8 100755 (executable)
 
 #include <stdio.h>
 #include <string.h>
+#include <sys/socket.h>
+#include <errno.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <fcntl.h>
+#include <netdb.h>
+#include <arpa/inet.h>
+#include <sys/signal.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/channel.h"
 #include "asterisk/config.h"
 #include "asterisk/app.h"
 #include "asterisk/musiconhold.h"
 #include "asterisk/manager.h"
-#include <sys/socket.h>
-#include <errno.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <fcntl.h>
-#include <netdb.h>
-#include <arpa/inet.h>
-#include <sys/signal.h>
 
 static const char desc[] = "Local Proxy Channel";
 static const char type[] = "Local";
index acac065..843af43 100755 (executable)
 
 #include <stdio.h>
 #include <string.h>
+#include <sys/socket.h>
+#include <sys/ioctl.h>
+#include <net/if.h>
+#include <errno.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <fcntl.h>
+#include <netdb.h>
+#include <arpa/inet.h>
+#include <sys/signal.h>
+#include <signal.h>
+#include <netinet/in_systm.h>
+#include <netinet/ip.h>
+#include <ctype.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/channel.h"
 #include "asterisk/config.h"
 #include "asterisk/musiconhold.h"
 #include "asterisk/utils.h"
 #include "asterisk/causes.h"
-#include <sys/socket.h>
-#include <sys/ioctl.h>
-#include <net/if.h>
-#include <errno.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <fcntl.h>
-#include <netdb.h>
-#include <arpa/inet.h>
-#include <sys/signal.h>
-#include <signal.h>
-#include <netinet/in_systm.h>
-#include <netinet/ip.h>
-
 #include "asterisk/dsp.h"
-#include <ctype.h>
 
 #ifndef IPTOS_MINCOST
 #define IPTOS_MINCOST 0x02
index ad80e3e..c1e61a0 100755 (executable)
 
 #include <stdio.h>
 #include <string.h>
-#include "asterisk/lock.h"
-#include "asterisk/channel.h"
-#include "asterisk/config.h"
-#include "asterisk/logger.h"
-#include "asterisk/module.h"
-#include "asterisk/pbx.h"
-#include "asterisk/options.h"
-#include "asterisk/vmodem.h"
-#include "asterisk/utils.h"
 #include <sys/socket.h>
 #include <sys/time.h>
 #include <errno.h>
 #include <sys/signal.h>
 #include <ctype.h>
 
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/lock.h"
+#include "asterisk/channel.h"
+#include "asterisk/config.h"
+#include "asterisk/logger.h"
+#include "asterisk/module.h"
+#include "asterisk/pbx.h"
+#include "asterisk/options.h"
+#include "asterisk/vmodem.h"
+#include "asterisk/utils.h"
+
 /* Up to 10 seconds for an echo to arrive */
 #define ECHO_TIMEOUT 10
 
index c14a8f6..ec6a35f 100755 (executable)
 #include <string.h>
 #include <stdlib.h>
 #include <errno.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/vmodem.h"
 #include "asterisk/module.h"
index aff1d5d..f1f6a90 100755 (executable)
 #include <stdlib.h>
 #include <errno.h>
 #include <unistd.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/vmodem.h"
 #include "asterisk/module.h"
index 65a2822..92cca42 100755 (executable)
 #include <errno.h>
 #include <unistd.h>
 #include <sys/ioctl.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/vmodem.h"
 #include "asterisk/module.h"
index fb5809c..1c72776 100755 (executable)
 
 #include <stdio.h>
 #include <string.h>
-#include "asterisk/lock.h"
-#include "asterisk/channel.h"
-#include "asterisk/config.h"
-#include "asterisk/logger.h"
-#include "asterisk/module.h"
-#include "asterisk/pbx.h"
-#include "asterisk/options.h"
 #include <sys/socket.h>
 #include <sys/time.h>
 #include <errno.h>
 #include <sys/ioctl.h>
 #include <nbs.h>
 
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/lock.h"
+#include "asterisk/channel.h"
+#include "asterisk/config.h"
+#include "asterisk/logger.h"
+#include "asterisk/module.h"
+#include "asterisk/pbx.h"
+#include "asterisk/options.h"
+
 static const char desc[] = "Network Broadcast Sound Support";
 static const char type[] = "NBS";
 static const char tdesc[] = "Network Broadcast Sound Driver";
index f52da8b..2d13446 100755 (executable)
  * the GNU General Public License
  */
 
-#include "asterisk/lock.h"
-#include "asterisk/frame.h"
-#include "asterisk/logger.h"
-#include "asterisk/channel.h"
-#include "asterisk/module.h"
-#include "asterisk/options.h"
-#include "asterisk/pbx.h"
-#include "asterisk/config.h"
-#include "asterisk/cli.h"
-#include "asterisk/utils.h"
-#include "asterisk/causes.h"
-#include "asterisk/endian.h"
 #include <unistd.h>
 #include <fcntl.h>
 #include <errno.h>
 #else
 #include <soundcard.h>
 #endif
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/lock.h"
+#include "asterisk/frame.h"
+#include "asterisk/logger.h"
+#include "asterisk/channel.h"
+#include "asterisk/module.h"
+#include "asterisk/options.h"
+#include "asterisk/pbx.h"
+#include "asterisk/config.h"
+#include "asterisk/cli.h"
+#include "asterisk/utils.h"
+#include "asterisk/causes.h"
+#include "asterisk/endian.h"
+
 #include "busy.h"
 #include "ringtone.h"
 #include "ring10.h"
index dd8aa65..513be4e 100755 (executable)
 #include <stdio.h>
 #include <string.h>
 #include <ctype.h>
-#include "asterisk/lock.h"
-#include "asterisk/channel.h"
-#include "asterisk/config.h"
-#include "asterisk/logger.h"
-#include "asterisk/module.h"
-#include "asterisk/pbx.h"
-#include "asterisk/options.h"
-#include "asterisk/utils.h"
-#include "asterisk/callerid.h"
-#include "asterisk/causes.h"
 #include <sys/socket.h>
 #include <sys/time.h>
 #include <errno.h>
 # include <linux/compiler.h>
 #endif
 #include <linux/ixjuser.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/lock.h"
+#include "asterisk/channel.h"
+#include "asterisk/config.h"
+#include "asterisk/logger.h"
+#include "asterisk/module.h"
+#include "asterisk/pbx.h"
+#include "asterisk/options.h"
+#include "asterisk/utils.h"
+#include "asterisk/callerid.h"
+#include "asterisk/causes.h"
 #include "DialTone.h"
 
 #ifdef QTI_PHONEJACK_TJ_PCI    /* check for the newer quicknet driver v.3.1.0 which has this symbol */
index e2cd3ac..f677d83 100755 (executable)
 #include <stdio.h>
 #include <ctype.h>
 #include <string.h>
+#include <sys/socket.h>
+#include <sys/ioctl.h>
+#include <net/if.h>
+#include <errno.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <fcntl.h>
+#include <netdb.h>
+#include <arpa/inet.h>
+#include <signal.h>
+#include <sys/signal.h>
+#include <netinet/in_systm.h>
+#include <netinet/ip.h>
+#include <regex.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/channel.h"
 #include "asterisk/config.h"
 #ifdef OSP_SUPPORT
 #include "asterisk/astosp.h"
 #endif
-#include <sys/socket.h>
-#include <sys/ioctl.h>
-#include <net/if.h>
-#include <errno.h>
-#include <unistd.h>
-#include <stdlib.h>
-#include <fcntl.h>
-#include <netdb.h>
-#include <arpa/inet.h>
-#include <signal.h>
-#include <sys/signal.h>
-#include <netinet/in_systm.h>
-#include <netinet/ip.h>
-#include <regex.h>
 
 #ifndef DEFAULT_USERAGENT
 #define DEFAULT_USERAGENT "Asterisk PBX"
index 2b058dd..e5fd4c9 100755 (executable)
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
+#include <sys/socket.h>
+#include <netinet/in.h>
+#include <netinet/tcp.h>
+#include <sys/ioctl.h>
+#include <net/if.h>
+#include <errno.h>
+#include <unistd.h>
+#include <fcntl.h>
+#include <netdb.h>
+#include <arpa/inet.h>
+#include <sys/signal.h>
+#include <signal.h>
+#include <ctype.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/channel.h"
 #include "asterisk/config.h"
 #include "asterisk/app.h"
 #include "asterisk/musiconhold.h"
 #include "asterisk/utils.h"
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <netinet/tcp.h>
-#include <sys/ioctl.h>
-#include <net/if.h>
-#include <errno.h>
-#include <unistd.h>
-#include <fcntl.h>
-#include <netdb.h>
-#include <arpa/inet.h>
-#include <sys/signal.h>
-#include <signal.h>
 #include "asterisk/dsp.h"
-#include <ctype.h>
 
 /************************************************************************************/
 /*                         Skinny/Asterisk Protocol Settings                        */
index ea66322..848c2b7 100755 (executable)
@@ -22,6 +22,11 @@ extern "C" {
 
 #include <stdio.h>
 #include <string.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/utils.h"
 #include "asterisk/channel.h"
@@ -33,7 +38,6 @@ extern "C" {
 #include "asterisk/callerid.h"
 #include "asterisk/dsp.h"
 #include "asterisk/features.h"
-
 }
 
 #include <sys/socket.h>
index 14b257c..bd72c71 100755 (executable)
 
 #include <stdio.h>
 #include <string.h>
-#include "asterisk/lock.h"
-#include "asterisk/channel.h"
-#include "asterisk/config.h"
-#include "asterisk/logger.h"
-#include "asterisk/module.h"
-#include "asterisk/pbx.h"
-#include "asterisk/options.h"
-#include "asterisk/file.h"
-#include "asterisk/ulaw.h"
-#include "asterisk/alaw.h"
-#include "asterisk/callerid.h"
-#include "asterisk/adsi.h"
-#include "asterisk/cli.h"
-#include "asterisk/cdr.h"
-#include "asterisk/features.h"
-#include "asterisk/musiconhold.h"
-#include "asterisk/say.h"
-#include "asterisk/tdd.h"
-#include "asterisk/app.h"
-#include "asterisk/dsp.h"
-#include "asterisk/astdb.h"
-#include "asterisk/manager.h"
-#include "asterisk/causes.h"
-#include "asterisk/term.h"
-#include "asterisk/utils.h"
-#include "asterisk/transcap.h"
 #include <sys/signal.h>
 #include <errno.h>
 #include <stdlib.h>
 
 #include "asterisk.h"
 
+ASTERISK_FILE_VERSION("$Revision$")
+
+#include "asterisk/lock.h"
+#include "asterisk/channel.h"
+#include "asterisk/config.h"
+#include "asterisk/logger.h"
+#include "asterisk/module.h"
+#include "asterisk/pbx.h"
+#include "asterisk/options.h"
+#include "asterisk/file.h"
+#include "asterisk/ulaw.h"
+#include "asterisk/alaw.h"
+#include "asterisk/callerid.h"
+#include "asterisk/adsi.h"
+#include "asterisk/cli.h"
+#include "asterisk/cdr.h"
+#include "asterisk/features.h"
+#include "asterisk/musiconhold.h"
+#include "asterisk/say.h"
+#include "asterisk/tdd.h"
+#include "asterisk/app.h"
+#include "asterisk/dsp.h"
+#include "asterisk/astdb.h"
+#include "asterisk/manager.h"
+#include "asterisk/causes.h"
+#include "asterisk/term.h"
+#include "asterisk/utils.h"
+#include "asterisk/transcap.h"
+
 #ifndef ZT_SIG_EM_E1
 #error "Your zaptel is too old.  please cvs update"
 #endif
index cb21253..dddf134 100755 (executable)
 #include <sys/socket.h>
 #include <string.h>
 #include <netinet/in.h>
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/frame.h"
 #include "asterisk/utils.h"
 #include "asterisk/unaligned.h"
index f44dcba..143c1b5 100755 (executable)
  *
  */
 
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION("$Revision$")
+
 #include "asterisk/config.h"
 #include "asterisk/logger.h"
 #include "asterisk/cli.h"