]> git.ipfire.org Git - thirdparty/shairport-sync.git/commitdiff
Discard non-sentinel packets at the start of a Realtime play -- they might belong...
authorMike Brady <4265913+mikebrady@users.noreply.github.com>
Fri, 28 Jan 2022 11:14:52 +0000 (11:14 +0000)
committerMike Brady <4265913+mikebrady@users.noreply.github.com>
Fri, 28 Jan 2022 11:14:52 +0000 (11:14 +0000)
rtp.c

diff --git a/rtp.c b/rtp.c
index c38ea96667c5bb7caecfcb7562f65ee3a3cfa2de..23af7708b866749b8d30c397367bb29a55495480 100644 (file)
--- a/rtp.c
+++ b/rtp.c
@@ -1426,7 +1426,7 @@ int get_ptp_anchor_local_time_info(rtsp_conn_info *conn, uint32_t *anchorRTP,
       debug(2, "Connection %d: No NQPTP master clock.", conn->connection_number);
       break;
     case clock_no_anchor_info:
-      debug(1, "Connection %d: No Clock Anchor.", conn->connection_number);
+      debug(1, "Connection %d: No clock anchor information.", conn->connection_number);
       break;
     case clock_version_mismatch:
       debug(1, "Connection %d: NQPTP clock interface mismatch.", conn->connection_number);
@@ -1664,12 +1664,8 @@ void *rtp_ap2_control_receiver(void *arg) {
 
     int64_t time_since_start = time_now - start_time;
 
-    if (time_since_start <= 10000000) {
-      debug(1, "Discarding early timing packet.");
-    }
-
     if (nread > 0) {
-      if ((time_since_start < 10000000) && ((packet[0] & 0x10) == 0)) {
+      if ((time_since_start < 2000000) && ((packet[0] & 0x10) == 0)) {
         debug(1,
               "Dropping what looks like a (non-sentinel) packet left over from a previous session "
               "at %f ms.",