|
|
41389a |
--- a/src/utils/wpa_debug.c
|
|
|
41389a |
+++ b/src/utils/wpa_debug.c
|
|
|
41389a |
@@ -75,6 +75,7 @@ void wpa_debug_print_timestamp(void)
|
|
|
41389a |
if (out_file) {
|
|
|
41389a |
fprintf(out_file, "%ld.%06u: ", (long) tv.sec,
|
|
|
41389a |
(unsigned int) tv.usec);
|
|
|
41389a |
+ fflush(out_file);
|
|
|
41389a |
} else
|
|
|
41389a |
#endif /* CONFIG_DEBUG_FILE */
|
|
|
41389a |
printf("%ld.%06u: ", (long) tv.sec, (unsigned int) tv.usec);
|
|
|
41389a |
@@ -221,6 +222,7 @@ void wpa_printf(int level, const char *f
|
|
|
41389a |
if (out_file) {
|
|
|
41389a |
vfprintf(out_file, fmt, ap);
|
|
|
41389a |
fprintf(out_file, "\n");
|
|
|
41389a |
+ fflush(out_file);
|
|
|
41389a |
} else {
|
|
|
41389a |
#endif /* CONFIG_DEBUG_FILE */
|
|
|
41389a |
vprintf(fmt, ap);
|
|
|
41389a |
@@ -357,6 +359,7 @@ static void _wpa_hexdump(int level, cons
|
|
|
41389a |
fprintf(out_file, " [REMOVED]");
|
|
|
41389a |
}
|
|
|
41389a |
fprintf(out_file, "\n");
|
|
|
41389a |
+ fflush(out_file);
|
|
|
41389a |
} else {
|
|
|
41389a |
#endif /* CONFIG_DEBUG_FILE */
|
|
|
41389a |
printf("%s - hexdump(len=%lu):", title, (unsigned long) len);
|
|
|
41389a |
@@ -425,12 +428,14 @@ static void _wpa_hexdump_ascii(int level
|
|
|
41389a |
fprintf(out_file,
|
|
|
41389a |
"%s - hexdump_ascii(len=%lu): [REMOVED]\n",
|
|
|
41389a |
title, (unsigned long) len);
|
|
|
41389a |
+ fflush(out_file);
|
|
|
41389a |
return;
|
|
|
41389a |
}
|
|
|
41389a |
if (buf == NULL) {
|
|
|
41389a |
fprintf(out_file,
|
|
|
41389a |
"%s - hexdump_ascii(len=%lu): [NULL]\n",
|
|
|
41389a |
title, (unsigned long) len);
|
|
|
41389a |
+ fflush(out_file);
|
|
|
41389a |
return;
|
|
|
41389a |
}
|
|
|
41389a |
fprintf(out_file, "%s - hexdump_ascii(len=%lu):\n",
|
|
|
41389a |
@@ -455,6 +460,7 @@ static void _wpa_hexdump_ascii(int level
|
|
|
41389a |
pos += llen;
|
|
|
41389a |
len -= llen;
|
|
|
41389a |
}
|
|
|
41389a |
+ fflush(out_file);
|
|
|
41389a |
} else {
|
|
|
41389a |
#endif /* CONFIG_DEBUG_FILE */
|
|
|
41389a |
if (!show) {
|