--- rtp.c.orig Wed May 11 20:40:37 2005 +++ rtp.c Thu May 12 09:38:08 2005 @@ -1140,10 +1140,11 @@ /* Get a pointer to the header */ rtpheader = (unsigned int *)data; rtpheader[0] = htonl((2 << 30) | (1 << 23) | (payload << 16) | (rtp->seqno++)); - rtpheader[1] = htonl(rtp->lastdigitts); + /* rtpheader[1] = htonl(rtp->lastdigitts); moved inside the loop */ rtpheader[2] = htonl(rtp->ssrc); rtpheader[3] = htonl((digit << 24) | (0xa << 16) | (0)); for (x=0;x<6;x++) { + rtpheader[1] = htonl(rtp->lastdigitts); if (rtp->them.sin_port && rtp->them.sin_addr.s_addr) { res = sendto(rtp->s, (void *)rtpheader, hdrlen + 4, 0, (struct sockaddr *)&rtp->them, sizeof(rtp->them)); if (res < 0) @@ -1161,6 +1162,7 @@ rtpheader[3] |= htonl((800)); /* Set the End bit for the last 3 */ rtpheader[3] |= htonl((1 << 23)); + rtp->lastdigitts++; /* or else the SPA3000 will click instead of beeping... */ } } /* Increment the digit timestamp by 120ms, to ensure that digits