Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP1:Update
pacemaker.3577
pacemaker-crm_mon-time-format-x32.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File pacemaker-crm_mon-time-format-x32.patch of Package pacemaker.3577
commit 9800c646d998130e4966b56dc1ef7c1fede1b3d0 Author: Christoph Berg <myon@debian.org> Date: Fri May 20 18:16:53 2016 +0200 Fix time formatting on x32 On x32, time_t is long long, but long is only 32bits, so sprintf("%ld", time_t) will error out. Fix by always casting to long long which is long enough on any platform. diff --git a/tools/crm_mon.c b/tools/crm_mon.c index 1fee391..b742aad 100644 --- a/tools/crm_mon.c +++ b/tools/crm_mon.c @@ -3302,7 +3302,7 @@ send_snmp_trap(const char *node, const char *rsc, const char *task, int target_r char csysuptime[20]; time_t now = time(NULL); - sprintf(csysuptime, "%ld", now); + sprintf(csysuptime, "%lld", (long long) now); snmp_add_var(trap_pdu, sysuptime_oid, sizeof(sysuptime_oid) / sizeof(oid), 't', csysuptime); }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor