#include <sys/stat.h>
#include <sys/socket.h>
#include <sys/types.h>
+#include <sys/sysmacros.h>
#include <linux/types.h>
#include <linux/netlink.h>
if (!timeout)
return;
+ if (!name)
+ return;
+
b = malloc(sizeof(*b));
- if (!b || !name)
+ if (!b)
return;
memset(b, 0, sizeof(*b));
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++)