[kdelibs] kded: Disable KHostnameD in KDED
Git commit 8d99f863724c6fe76d008da4455fa177af2ee3ee by Àlex Fiestas. Committed on 15/04/2013 at 12:24. Pushed by afiestas into branch 'master'. Disable KHostnameD in KDED KHostnameD monitors the hostname by polling gethostname every 5 seconds to adapt some bits of the environment in case the hostname changes. In systems with only a local X server this does not matter at all. In systems using remote X you should not change your hostname, period. In most distributions changing your hostname no longuer breaks X access for local applications since xhost is configured correctly. In summary there is NO reason to keep this around. Besides that, kdontchangethehostname (binay that is called when the hostname is changed) does not work if your DISPLAY env is like ":0" which is the format that can be found in all distributions nowdays (old format was domain/[unix,tcp,...]:0). Even fixing it, most distributions use a global Xauthority pointed by the DM or XAUTHORITY env which points to either /run/*dm/... or in /tmp/user Meaning that the most important adaptation to the new hostname that kdontchangethehostname does won't work either. If this is ever enabled again the polling should be removed by either using systemd-hostnamed or inotify+/etc/hostname but polling won't be accepted. This commits only disables the code, if nobody complains I will remove the full code before 4.11 is out. CCMAIL:kde-core-devel@kde.org M +1-1kded/kded.cpp http://commits.kde.org/kdelibs/8d99f863724c6fe76d008da4455fa177af2ee3ee diff --git a/kded/kded.cpp b/kded/kded.cpp index b594692..b611972 100644 --- a/kded/kded.cpp +++ b/kded/kded.cpp @@ -842,7 +842,7 @@ public: #endif if (bCheckHostname) -(void) new KHostnameD(HostnamePollInterval); // Watch for hostname changes +// (void) new KHostnameD(HostnamePollInterval); // Watch for hostname changes kded->initModules(); } else
Re: [kdelibs] kded: Disable KHostnameD in KDED
Am 15.04.2013 12:43, schrieb Àlex Fiestas: Git commit 8d99f863724c6fe76d008da4455fa177af2ee3ee by Àlex Fiestas. Committed on 15/04/2013 at 12:24. Pushed by afiestas into branch 'master'. Disable KHostnameD in KDED KHostnameD monitors the hostname by polling gethostname every 5 seconds to adapt some bits of the environment in case the hostname changes. In systems with only a local X server this does not matter at all. In systems using remote X you should not change your hostname, period. In most distributions changing your hostname no longuer breaks X access for local applications since xhost is configured correctly. In summary there is NO reason to keep this around. Besides that, kdontchangethehostname (binay that is called when the hostname is changed) does not work if your DISPLAY env is like ":0" which is the format that can be found in all distributions nowdays (old format was domain/[unix,tcp,...]:0). Even fixing it, most distributions use a global Xauthority pointed by the DM or XAUTHORITY env which points to either /run/*dm/... or in /tmp/user Meaning that the most important adaptation to the new hostname that kdontchangethehostname does won't work either. If this is ever enabled again the polling should be removed by either using systemd-hostnamed or inotify+/etc/hostname but polling won't be accepted. This commits only disables the code, if nobody complains I will remove the full code before 4.11 is out. CCMAIL:kde-core-devel@kde.org M +1-1kded/kded.cpp http://commits.kde.org/kdelibs/8d99f863724c6fe76d008da4455fa177af2ee3ee diff --git a/kded/kded.cpp b/kded/kded.cpp index b594692..b611972 100644 --- a/kded/kded.cpp +++ b/kded/kded.cpp @@ -842,7 +842,7 @@ public: #endif if (bCheckHostname) -(void) new KHostnameD(HostnamePollInterval); // Watch for hostname changes +// (void) new KHostnameD(HostnamePollInterval); // Watch for hostname changes kded->initModules(); } else Nice, now we have if (bCheckHostname) kded->initModules(); This can't be right. Eike
Re: [kdelibs] kded: Disable KHostnameD in KDED
On Mon, Apr 15, 2013 at 12:43:21PM +0200, Àlex Fiestas wrote: > Git commit 8d99f863724c6fe76d008da4455fa177af2ee3ee by Àlex Fiestas. > Committed on 15/04/2013 at 12:24. > Pushed by afiestas into branch 'master'. I thought kdelibs master was closed for everything except bug fixes? And why didn't this go through reviewboard? -- Martin Sandsmark
Re: [kdelibs] kded: Disable KHostnameD in KDED
On Monday 15 April 2013 12:43:21 Àlex Fiestas wrote: > This commits only disables the code, if nobody complains I will remove > the full code before 4.11 is out. +1 to remove that code -- Martin Gräßlin signature.asc Description: This is a digitally signed message part.
Re: [kdelibs] kded: Disable KHostnameD in KDED
On Monday, April 15, 2013 13:39:34 Martin Sandsmark wrote: > On Mon, Apr 15, 2013 at 01:17:19PM +0200, Martin Gräßlin wrote: > > well not stupidly polling is a bug fix, isn't it? > > That's really trying to twist semantics, IMHO. Polling every five seconds > like it is intended to is not a bug, Polling every 5 seconds for a file that is rarely changed is a bug. This kind of thing would nowadays, rightfully, never be accepted. If this monitoring of the hostname is needed at all, it should be done using filewatch, not polling. -- sebas http://www.kde.org | http://vizZzion.org | GPG Key ID: 9119 0EF9
Re: [kdelibs] kded: Disable KHostnameD in KDED
On Mon, Apr 15, 2013 at 02:04:43PM +0200, Sebastian Kügler wrote: > Polling every 5 seconds for a file that is rarely changed is a bug. What functionality does it break? I'm not saying it's not suboptimal, and it can be solved in better ways, but I would in no way consider this a bug fix. -- Martin Sandsmark
Re: [kdelibs] kded: Disable KHostnameD in KDED
2013/4/15 Martin Sandsmark : > On Mon, Apr 15, 2013 at 02:04:43PM +0200, Sebastian Kügler wrote: >> Polling every 5 seconds for a file that is rarely changed is a bug. > > What functionality does it break? I have seem this code before and would ask the same thing, it breaks the kded daemon being able to sleep which from the power saving point of view it's a bug, but indeed a review would be better, and if someone really needs this a watcher would be the proper fix. > > I'm not saying it's not suboptimal, and it can be solved in better ways, but > I would in no way consider this a bug fix. > > -- > Martin Sandsmark > -- Daniel Nicoletti KDE Developer - http://dantti.wordpress.com
Re: Re: [kdelibs] kded: Disable KHostnameD in KDED
On Monday 15 April 2013 13:10:09 Martin Sandsmark wrote: > On Mon, Apr 15, 2013 at 12:43:21PM +0200, Àlex Fiestas wrote: > > Git commit 8d99f863724c6fe76d008da4455fa177af2ee3ee by Àlex Fiestas. > > Committed on 15/04/2013 at 12:24. > > Pushed by afiestas into branch 'master'. > > I thought kdelibs master was closed for everything except bug fixes? well not stupidly polling is a bug fix, isn't it? > > And why didn't this go through reviewboard? I think in this case it is fine, after all core-devel is on CC and the code is not yet removed -- Martin Gräßlin signature.asc Description: This is a digitally signed message part.
Re: Re: [kdelibs] kded: Disable KHostnameD in KDED
On Mon, Apr 15, 2013 at 01:17:19PM +0200, Martin Gräßlin wrote: > well not stupidly polling is a bug fix, isn't it? That's really trying to twist semantics, IMHO. Polling every five seconds like it is intended to is not a bug, and now it breaks even worse (by locking out everyone who change their hostname from their sessions, not just with a different X setup). > I think in this case it is fine, after all core-devel is on CC and the code > is > not yet removed The point of reviews is to catch stupid mistakes like the one Rolf pointed out (and preferrably have this discussion before-hand, instead of having to go in and revert stuff). -- Martin Sandsmark