diff options
author | bweschke <bweschke@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-10-19 19:07:05 +0000 |
---|---|---|
committer | bweschke <bweschke@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-10-19 19:07:05 +0000 |
commit | 275b9c5aa6af688091d95f9c259fce1903e9be4f (patch) | |
tree | 3e4e4cd4928232bd57b64c36d5c6584ce96cdbb2 /main/asterisk.c | |
parent | 7794d425c0941bc35b9854e78c390f147ac78059 (diff) |
Fix the 1.4 branch compile again broken with r150557 when using with Zaptel and not DAHDI
(closes issue #13740)
reported by: jmls
patch by: bweschke
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@151100 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/asterisk.c')
-rw-r--r-- | main/asterisk.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/main/asterisk.c b/main/asterisk.c index c7fe4b82e..c3191711d 100644 --- a/main/asterisk.c +++ b/main/asterisk.c @@ -74,11 +74,18 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$") #include <pwd.h> #include <sys/stat.h> -#if defined(HAVE_DAHDI) +#if defined(HAVE_ZAPTEL) || defined (HAVE_DAHDI) #include <sys/ioctl.h> +#endif + +#if defined(HAVE_DAHDI) #include "asterisk/dahdi_compat.h" #endif +#if defined(HAVE_ZAPTEL) +#include <zaptel/zaptel.h> +#endif + #ifdef linux #include <sys/prctl.h> #ifdef HAVE_CAP @@ -2991,7 +2998,7 @@ int main(int argc, char *argv[]) int x = 160; fd = open("/dev/zap/timer", O_RDWR); if (fd >= 0) { - if (ioctl(fd, DAHDI_TIMERCONFIG, &x)) { + if (ioctl(fd, ZT_TIMERCONFIG, &x)) { ast_log(LOG_ERROR, "You have Zaptel built and drivers loaded, but the Zaptel timer test failed to set ZT_TIMERCONFIG to %d.\n", x); exit(1); } |