Browse Source

procd: add missing new lines inside debug code

Signed-off-by: John Crispin <john@phrozen.org>
John Crispin 6 years ago
parent
commit
3ba6b45c59
2 changed files with 5 additions and 7 deletions
  1. 1 1
      log.h
  2. 4 6
      plug/hotplug.c

+ 1 - 1
log.h

@@ -19,7 +19,7 @@
 
 #define DEBUG(level, fmt, ...) do { \
 	if (debug >= level) { \
-		ulog(LOG_DEBUG, fmt, ## __VA_ARGS__); \
+		ulog(LOG_NOTICE, fmt, ## __VA_ARGS__); \
 	} } while (0)
 
 #define LOG   ULOG_INFO

+ 4 - 6
plug/hotplug.c

@@ -492,15 +492,13 @@ static void rule_handle_command(struct json_script_ctx *ctx, const char *name,
 	int rem, i;
 
 	if (debug > 3) {
-		DEBUG(4, "Command: %s", name);
+		DEBUG(4, "Command: %s\n", name);
 		blobmsg_for_each_attr(cur, data, rem)
-			DEBUG(4, " %s", (char *) blobmsg_data(cur));
-		DEBUG(4, "\n");
+			DEBUG(4, " %s\n", (char *) blobmsg_data(cur));
 
-		DEBUG(4, "Message:");
+		DEBUG(4, "Message:\n");
 		blobmsg_for_each_attr(cur, vars, rem)
-			DEBUG(4, " %s=%s", blobmsg_name(cur), (char *) blobmsg_data(cur));
-		DEBUG(4, "\n");
+			DEBUG(4, " %s=%s\n", blobmsg_name(cur), (char *) blobmsg_data(cur));
 	}
 
 	for (i = 0; i < ARRAY_SIZE(handlers); i++)