wsman-debug: fix possible NULL dereference
@@ -72,9 +72,11 @@ wsman_debug_message_handler(const char *str, debug_level_e level, void *user_dat
time(&now);
tm = localtime(&now);
+ if (tm) {
strftime(timestr, 128, "%b %e %T", tm);
fprintf(stderr, "%s %s\n", timestr, str);
}
}
+}
