GNOME Bugzilla – Bug 732021
Automatic Date & Time row is displayed even if NTP is unavailable
Last modified: 2014-06-23 16:51:14 UTC
The datetime panel has logic to hide the Automatic Date & Time row if NTP is unavailable (based on timedated's CanNTP property), but this logic is broken and the row is displayed unconditionally.
Created attachment 278917 [details] [review] datetime: fix check for CanNTP If the system does not support NTP (as determined by the presence of an NTP unit in /usr/lib/systemd/ntp-units.d), the Automatic Date & Time row is intended to be hidden. We respond to changes to timedated's CanNTP property, but we never account for the initial state of the property, so we wind up displaying the Automatic Date & Time row even though the switch is guaranteed to be broken. Check CanNTP when initializing the panel to fix this.
Review of attachment 278917 [details] [review]: Code looks fine, thanks. Please make the patch summary more explicit, something like: datetime: Check CanNTP when initializing the panel
Created attachment 279055 [details] [review] datetime: check CanNTP when initializing the panel If the system does not support NTP (as determined by the presence of an NTP unit in /usr/lib/systemd/ntp-units.d), the Automatic Date & Time row is intended to be hidden. We respond to changes to timedated's CanNTP property, but we never account for the initial state of the property, so we wind up displaying the Automatic Date & Time row even though the switch is guaranteed to be broken. Check CanNTP when initializing the panel to fix this.
Thanks Attachment 279055 [details] pushed as c865480 - datetime: check CanNTP when initializing the panel