forked from pool/ipmitool
Thomas Renninger
31281a73e0
1) exchange-bmc-os-info - fate#315999 Shows SLES string as OS in the service processor info 2) bmc-snmp-proxy - fate#316000 Exports sel (BMC Error log) via snmpd 3) ipmievd - fate#316002 Logs sel to syslog 1. and 2. are very Dell specific and should not get enabled by default 3. got converted to a native systemd service. Still needs autoconf adjusting to get send mainline 1. and 2. have somewhat bigger Init V init scripts and time was not enough to convert them. Therefore they were added via insserv and friends as well OBS-URL: https://build.opensuse.org/package/show/systemsmanagement/ipmitool?expand=0&rev=20
36 lines
1017 B
Diff
36 lines
1017 B
Diff
Index: ipmitool-1.8.13/lib/helper.c
|
|
===================================================================
|
|
--- ipmitool-1.8.13.orig/lib/helper.c
|
|
+++ ipmitool-1.8.13/lib/helper.c
|
|
@@ -657,7 +657,6 @@ ipmi_start_daemon(struct ipmi_intf *intf
|
|
#endif
|
|
|
|
chdir("/");
|
|
- umask(0);
|
|
|
|
for (fd=0; fd<64; fd++) {
|
|
if (fd != intf->fd)
|
|
Index: ipmitool-1.8.13/src/ipmievd.c
|
|
===================================================================
|
|
--- ipmitool-1.8.13.orig/src/ipmievd.c
|
|
+++ ipmitool-1.8.13/src/ipmievd.c
|
|
@@ -700,6 +700,7 @@ ipmievd_main(struct ipmi_event_intf * ei
|
|
int i, rc;
|
|
int daemon = 1;
|
|
struct sigaction act;
|
|
+ mode_t oldumask;
|
|
|
|
memset(pidfile, 0, 64);
|
|
sprintf(pidfile, "%s%d", DEFAULT_PIDFILE, eintf->intf->devnum);
|
|
@@ -761,8 +762,9 @@ ipmievd_main(struct ipmi_event_intf * ei
|
|
|
|
ipmi_start_daemon(eintf->intf);
|
|
|
|
- umask(022);
|
|
+ oldumask = umask(022);
|
|
fp = ipmi_open_file_write(pidfile);
|
|
+ umask(oldumask);
|
|
if (fp == NULL) {
|
|
/* Failed to get fp on PID file -> exit. */
|
|
log_halt();
|