diff options
author | mattf <mattf@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2007-07-27 19:32:25 +0000 |
---|---|---|
committer | mattf <mattf@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2007-07-27 19:32:25 +0000 |
commit | b712f06fa3cb4454234ff62e1db02f75ff837a0b (patch) | |
tree | 13a2c7ebc87e6258419755f8bf2b97ced2a8f3e7 /fxotune.c | |
parent | 7e67a7f820d47dee9c2c302962732a6fa814ac1e (diff) |
Quick fix for could not fill input buffer errors
git-svn-id: http://svn.digium.com/svn/zaptel/branches/1.2@2786 5390a7c7-147a-4af0-8ec9-7488f05a26cb
Diffstat (limited to 'fxotune.c')
-rw-r--r-- | fxotune.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -231,11 +231,15 @@ static int acim_tune(int whichzap, char *dialstr) return -1; } +retry: /* read return response */ res = read(whichzap, inbuf, BUFFER_LENGTH); if (res != BUFFER_LENGTH) { - fprintf(stderr, "Could not fill input buffer\n"); - return -1; + int x; + + ioctl(whichzap, ZT_GETEVENT, &x); + goto retry; + } /* calculate power of response */ |