diff options
author | mattf <mattf@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2007-04-11 19:01:21 +0000 |
---|---|---|
committer | mattf <mattf@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2007-04-11 19:01:21 +0000 |
commit | bde8d228274e7e9e708837fd5c7a5561aa7e6255 (patch) | |
tree | 50a8eea363f19019ee3a9142dc62ce7cff073031 /zaptel-base.c | |
parent | 6e42b175c8c81c84bbe09aa7c4c51b9a3522fcfe (diff) |
Fix buglet in memory corruption fix.
git-svn-id: http://svn.digium.com/svn/zaptel/branches/1.2@2405 5390a7c7-147a-4af0-8ec9-7488f05a26cb
Diffstat (limited to 'zaptel-base.c')
-rw-r--r-- | zaptel-base.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/zaptel-base.c b/zaptel-base.c index 842a145..0b34057 100644 --- a/zaptel-base.c +++ b/zaptel-base.c @@ -1728,7 +1728,7 @@ static ssize_t zt_chan_read(struct file *file, char *usrbuf, size_t count, int u chan->readidx[res] = 0; chan->readn[res] = 0; oldbuf = res; - res = (chan->outreadbuf + 1) % chan->numbufs; + chan->outreadbuf = (res + 1) % chan->numbufs; if (chan->outreadbuf == chan->inreadbuf) { /* Out of stuff */ chan->outreadbuf = -1; |