summaryrefslogtreecommitdiff
path: root/zaptel.c
diff options
context:
space:
mode:
authormarkster <markster@5390a7c7-147a-4af0-8ec9-7488f05a26cb>2003-10-24 19:51:33 +0000
committermarkster <markster@5390a7c7-147a-4af0-8ec9-7488f05a26cb>2003-10-24 19:51:33 +0000
commit3d4261ec70978e7ca4dd833b5c913c64771efd7c (patch)
tree21dcdd91212427501ee8a0efee91e2ae00cede88 /zaptel.c
parent5d65033efcc9841323d9ca6e892017199b7341d3 (diff)
Increase max buffer size
git-svn-id: http://svn.digium.com/svn/zaptel/trunk@258 5390a7c7-147a-4af0-8ec9-7488f05a26cb
Diffstat (limited to 'zaptel.c')
-rwxr-xr-xzaptel.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/zaptel.c b/zaptel.c
index 4fc7da6..b5589d1 100755
--- a/zaptel.c
+++ b/zaptel.c
@@ -3049,6 +3049,8 @@ static int zt_chanandpseudo_ioctl(struct inode *inode, struct file *file, unsign
return -EINVAL;
if (bi.bufsize < 16)
return -EINVAL;
+ if (bi.bufsize * bi.numbufs > ZT_MAX_BUF_SPACE)
+ return -EINVAL;
chan->rxbufpolicy = bi.rxbufpolicy & 0x1;
chan->txbufpolicy = bi.txbufpolicy & 0x1;
if ((rv = zt_reallocbufs(chan, bi.bufsize, bi.numbufs)))