#include "lib/pow2.h"
static char __run_str[REAL_MAX_JOBS + 1];
-static char run_str[__THREAD_RUNSTR_SZ(REAL_MAX_JOBS)];
+static char run_str[__THREAD_RUNSTR_SZ(REAL_MAX_JOBS) + 1];
static void update_condensed_str(char *rstr, char *run_str_condensed)
{
rate_str[DDIR_READ], rate_str[DDIR_WRITE],
iops_str[DDIR_READ], iops_str[DDIR_WRITE],
eta_str);
+ /* If truncation occurred adjust l so p is on the null */
+ if (l >= left)
+ l = left - 1;
p += l;
if (l >= 0 && l < linelen_last)
p += sprintf(p, "%*s", linelen_last - l, "");