mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-27 15:32:52 +02:00
setting_helpers: write /etc/timezone for better compatibility
Origin commit data
------------------
Branch: ni/coolstream
Commit: c9c3c01e92
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2014-10-11 (Sat, 11 Oct 2014)
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
@@ -509,6 +509,12 @@ bool CTZChangeNotifier::changeNotify(const neutrino_locale_t, void * Data)
|
||||
perror("unlink failed");
|
||||
if (symlink(cmd.c_str(), "/etc/localtime"))
|
||||
perror("symlink failed");
|
||||
/* for yocto tzdata compatibility */
|
||||
FILE *f = fopen("/etc/timezone", "w");
|
||||
if (f) {
|
||||
fprintf(f, "%s\n", zone.c_str());
|
||||
fclose(f);
|
||||
}
|
||||
#if 0
|
||||
cmd = ":" + zone;
|
||||
setenv("TZ", cmd.c_str(), 1);
|
||||
|
Reference in New Issue
Block a user