diff options
author | kpfleming <kpfleming@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2005-06-21 23:52:40 +0000 |
---|---|---|
committer | kpfleming <kpfleming@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2005-06-21 23:52:40 +0000 |
commit | 7876ba00032d1117816414899497de867bf3eb31 (patch) | |
tree | 8726c2acbfe4e1d46f60b140e0f58e7f59249229 | |
parent | 56270d3698dc53f439a7fc8f7c26c10b0d79bc0c (diff) |
correct ZT_TONE_CALLWAIT for de and dk zones (bug #4519)
git-svn-id: http://svn.digium.com/svn/zaptel/trunk@680 5390a7c7-147a-4af0-8ec9-7488f05a26cb
-rwxr-xr-x | tonezone.c | 5 | ||||
-rwxr-xr-x | zaptel.c | 2 | ||||
-rwxr-xr-x | zonedata.c | 4 |
3 files changed, 7 insertions, 4 deletions
@@ -123,7 +123,7 @@ static int build_tone(char *data, int size, struct tone_zone_sound *t, int *coun return -1; } #if 0 - printf("Using %d samples for %d and %d\n", samples, freq1, freq2); + printf("Using %d samples for %d and %d\n", time * 8, freq1, freq2); #endif if (size < sizeof(struct zt_tone_def)) { fprintf(stderr, "Not enough space for samples\n"); @@ -164,6 +164,9 @@ static int build_tone(char *data, int size, struct tone_zone_sound *t, int *coun /* If we don't end on a solid tone, return */ td->next = firstnobang; } + if (firstnobang < 0) + fprintf(stderr, "tone '%s' does not end with a solid tone or silence (all tone components have an exclamation mark)\n", t->data); + return used; } @@ -2420,7 +2420,7 @@ ioctl_load_zone(unsigned long data) next[x] = td.next; /* Make sure the "next" one is sane */ if ((next[x] >= th.count) || (next[x] < 0)) { - printk("Invalid 'next' pointer\n"); + printk("Invalid 'next' pointer: %d\n", next[x]); kfree(slab); return -EINVAL; } @@ -460,7 +460,7 @@ struct tone_zone builtin_zones[] = { ZT_TONE_BUSY, "425/480,0/480" }, { ZT_TONE_RINGTONE, "425/1000,0/4000" }, { ZT_TONE_CONGESTION, "425/240,0/240" }, - { ZT_TONE_CALLWAIT, "!425/200,!0/200,!425/200,!0/5000,!425/200,!0/200,!425/200,!0/5000,!425/200,!0/200,!425/200,!0/5000,!425/200,!0/200,!425/200,!0/5000,!425/200,!0/200,!425/200" }, + { ZT_TONE_CALLWAIT, "!425/200,!0/200,!425/200,!0/5000,!425/200,!0/200,!425/200,!0/5000,!425/200,!0/200,!425/200,!0/5000,!425/200,!0/200,!425/200,!0/5000,!425/200,!0/200,!425/200,0" }, /* DIALRECALL - not specified */ { ZT_TONE_DIALRECALL, "!425/100,!0/100,!425/100,!0/100,!425/100,!0/100,425" }, /* RECORDTONE - not specified */ @@ -492,7 +492,7 @@ struct tone_zone builtin_zones[] = { ZT_TONE_BUSY, "425/500,0/500" }, { ZT_TONE_RINGTONE, "425/1000,0/4000" }, { ZT_TONE_CONGESTION, "425/200,0/200" }, - { ZT_TONE_CALLWAIT, "!425/200,!0/600,!425/200,!0/3000,!425/200,!0/200,!425/200" }, + { ZT_TONE_CALLWAIT, "!425/200,!0/600,!425/200,!0/3000,!425/200,!0/200,!425/200,0" }, /* DIALRECALL - not specified */ { ZT_TONE_DIALRECALL, "!425/100,!0/100,!425/100,!0/100,!425/100,!0/100,425" }, /* RECORDTONE - not specified */ |