Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 18 lines 741 B view raw
1Index: plasma-desktop-5.8.5/kcms/dateandtime/helper.cpp 2=================================================================== 3--- plasma-desktop-5.8.5.orig/kcms/dateandtime/helper.cpp 4+++ plasma-desktop-5.8.5/kcms/dateandtime/helper.cpp 5@@ -181,7 +181,12 @@ int ClockHelper::tz( const QString& sele 6 7 val = selectedzone; 8 #else 9- QString tz = "/usr/share/zoneinfo/" + selectedzone; 10+ QString tzdir = QString::fromLocal8Bit(qgetenv("TZDIR")); 11+ QString tz = tzdir + "/" + selectedzone; 12+ if (tzdir.isEmpty()) { 13+ // Standard Linux path 14+ tz = "/usr/share/zoneinfo/" + selectedzone; 15+ } 16 17 if (QFile::exists(tz)) { // make sure the new TZ really exists 18 QFile::remove(QStringLiteral("/etc/localtime"));