[packages/thermal-daemon] make printing time_t more portable
atler
atler at pld-linux.org
Mon Jun 29 19:29:05 CEST 2020
commit 844282068bb6e60ffb47b4323933e22ad0f26bb1
Author: Jan Palus <atler at pld-linux.org>
Date: Mon Jun 29 19:27:50 2020 +0200
make printing time_t more portable
print-time_t.patch | 14 ++++++++++++++
thermal-daemon.spec | 2 ++
2 files changed, 16 insertions(+)
---
diff --git a/thermal-daemon.spec b/thermal-daemon.spec
index 22ab883..9692542 100644
--- a/thermal-daemon.spec
+++ b/thermal-daemon.spec
@@ -7,6 +7,7 @@ License: GPL v2+
Group: Base
Source0: https://github.com/01org/thermal_daemon/archive/v%{version}/%{name}-%{version}.tar.gz
# Source0-md5: 4e86f9c2fedcdfc10bb2654edcc96414
+Patch0: print-time_t.patch
URL: https://github.com/01org/thermal_daemon
BuildRequires: autoconf >= 2.50
BuildRequires: automake >= 1:1.11
@@ -32,6 +33,7 @@ Thermal Daemon monitoruje i kontroluje temperaturę komputera.
%prep
%setup -q -n thermal_daemon-%{version}
+%patch0 -p1
%build
install -d build-aux
diff --git a/print-time_t.patch b/print-time_t.patch
new file mode 100644
index 0000000..99a0878
--- /dev/null
+++ b/print-time_t.patch
@@ -0,0 +1,14 @@
+--- thermal_daemon-2.2/src/main.cpp.orig 2020-06-06 01:02:24.000000000 +0200
++++ thermal_daemon-2.2/src/main.cpp 2020-06-29 19:26:49.136677166 +0200
+@@ -121,9 +121,9 @@
+ seconds = time(NULL);
+
+ if (thd_daemonize)
+- syslog(syslog_priority, "[%ld]%s%s", seconds, prefix, message);
++ syslog(syslog_priority, "[%lld]%s%s", (long long) seconds, prefix, message);
+ else
+- g_print("[%ld]%s%s", seconds, prefix, message);
++ g_print("[%lld]%s%s", (long long) seconds, prefix, message);
+
+ }
+
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/thermal-daemon.git/commitdiff/844282068bb6e60ffb47b4323933e22ad0f26bb1
More information about the pld-cvs-commit
mailing list