src/ntpd.c: Format refclock name and unit ID with %s-%u
authorJohan Kiviniemi <devel@johan.kiviniemi.name>
Thu, 4 Oct 2012 21:24:19 +0000 (00:24 +0300)
committerJohan Kiviniemi <devel@johan.kiviniemi.name>
Thu, 4 Oct 2012 22:04:05 +0000 (01:04 +0300)
src/ntpd.c

index 15e60a5..3e2b4ea 100644 (file)
@@ -859,7 +859,7 @@ static int ntpd_read (void)
                        {
                                /* The unit number is in the lowest byte. */
                                ssnprintf (peername, sizeof (peername),
-                                               "%s%i",
+                                               "%s-%u",
                                                refclock_names[refclock_id],
                                                ntohl (ptr->srcadr) & 0xFF);
                        }