]> git.ipfire.org Git - thirdparty/chrony.git/commitdiff
ntp: fix NSR_TakeSourcesOffline()
authorMiroslav Lichvar <mlichvar@redhat.com>
Fri, 26 Sep 2014 13:25:33 +0000 (15:25 +0200)
committerMiroslav Lichvar <mlichvar@redhat.com>
Fri, 26 Sep 2014 13:27:08 +0000 (15:27 +0200)
This was broken when switching to dynamic allocation in commit 9e7193.

ntp_sources.c

index 8afef5e1dec5c7972fc763f039a6eb59ff548cc2..a81007aa39addabfb7ac2d957a579a98e9ee4ebd 100644 (file)
@@ -610,7 +610,7 @@ NSR_TakeSourcesOffline(IPAddr *mask, IPAddr *address)
   }
 
   /* Take sync peer offline as last to avoid reference switching */
-  if (syncpeer >= 0) {
+  if (syncpeer) {
     NCR_TakeSourceOffline(syncpeer->data);
   }