Signed-off-by: Angus Salkeld <asalkeld(a)redhat.com>
---
include/qb/qblog.h | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/qb/qblog.h b/include/qb/qblog.h
index 132bb54..37f0edd 100644
--- a/include/qb/qblog.h
+++ b/include/qb/qblog.h
@@ -328,8 +328,8 @@ void qb_log_from_external_source(const char *function,
#define qb_perror
#endif
-#define qb_enter() qb_log(LOG_TRACE, "entering %s()", __func__)
-#define qb_leave() qb_log(LOG_TRACE, "leaving %s()", __func__)
+#define qb_enter() qb_log(LOG_TRACE, "ENTERING %s()", __func__)
+#define qb_leave() qb_log(LOG_TRACE, "LEAVING %s()", __func__)
#define QB_LOG_SYSLOG 0
#define QB_LOG_STDERR 1
--
1.7.5
Show replies by date
Signed-off-by: Angus Salkeld <asalkeld(a)redhat.com>
---
lib/log_format.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/lib/log_format.c b/lib/log_format.c
index e2c5afa..2431f5c 100644
--- a/lib/log_format.c
+++ b/lib/log_format.c
@@ -191,5 +191,9 @@ void qb_log_target_format(struct qb_log_target *t,
}
}
- output_buffer[output_buffer_idx] = '\0';
+ if (output_buffer[output_buffer_idx-1] == '\n') {
+ output_buffer[output_buffer_idx-1] = '\0';
+ } else {
+ output_buffer[output_buffer_idx] = '\0';
+ }
}
--
1.7.5