summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/monitor/monitor_sbus.c2
-rw-r--r--src/util/debug.c3
2 files changed, 4 insertions, 1 deletions
diff --git a/src/monitor/monitor_sbus.c b/src/monitor/monitor_sbus.c
index 43e5b685..034cd46d 100644
--- a/src/monitor/monitor_sbus.c
+++ b/src/monitor/monitor_sbus.c
@@ -184,7 +184,7 @@ int monitor_common_rotate_logs(DBusMessage *message,
ret = rotate_debug_files();
if (ret) {
- DEBUG(1, ("Could not rotate debug files!\n"));
+ sss_log(SSS_LOG_ALERT, "Could not rotate debug files!\n");
return ret;
}
diff --git a/src/util/debug.c b/src/util/debug.c
index 5b6fccd6..30026dc1 100644
--- a/src/util/debug.c
+++ b/src/util/debug.c
@@ -132,8 +132,11 @@ int open_debug_file_ex(const char *filename, FILE **filep)
if (debug_file && !filep) fclose(debug_file);
old_umask = umask(0177);
+ errno = 0;
f = fopen(logpath, "a");
if (f == NULL) {
+ sss_log(SSS_LOG_EMERG, "Could not open file [%s]. Error: [%d][%s]\n",
+ logpath, errno, strerror(errno));
free(logpath);
return EIO;
}