[Home]

Summary:ASTERISK-00644: [patch] ast_rtp_read doesn't retry on improperly returned recvfrom
Reporter:jjanzer (jjanzer)Labels:
Date Opened:2003-12-09 13:32:25.000-0600Date Closed:2011-06-07 14:11:59
Priority:TrivialRegression?No
Status:Closed/CompleteComponents:Core/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) rtpRecvFrom.patch
Description:I can reproduce a warning by calling festival with any message, at which point I will get the error:
WARNING[262161]: File rtp.c, Line 375 (ast_rtp_read): RTP Read error: Resource temporarily unavailable

I fixed this in the attached patch (rtpRecvFrom.patch), by giving any errors to recvfrom a 10th of a second retry up to 3 times.
Comments:By: Mark Spencer (markster) 2003-12-09 14:42:49.000-0600

IF you look at the traffic with ethereal, i think you'll find that the read returns -EAGAIN when there is a packet which fails checksum that is received, and thus going to read again does no good.  Besides, after it returns, it immediately is polling for read again anyway so even if we didn't read, there's no reason to wait around.

By: jrollyson (jrollyson) 2004-01-11 17:35:01.000-0600

If I understand this properly, * is behaving sanely by displaying this error - it simply means that a damaged packet was discarded. In this case, just dropping the bad packet and continuing will have negligable impact on audio quality, waiting for retry seems pointless.

By: Brian West (bkw918) 2004-01-11 20:11:52.000-0600

This isn't a bug.