Skip to content

Commit

Permalink
dbg_namecode() bug fix for an unmatched code
Browse files Browse the repository at this point in the history
  • Loading branch information
cezanne committed Jun 11, 2020
1 parent e180b6d commit 9623f29
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion driver/lib/dbgcode.c
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,8 @@ dbg_namecode(namecode_t *namecodes, const char *codetype, unsigned int code)
nwritten += libdrv_snprintf(buf + nwritten, NAMECODE_BUF_MAX - nwritten, ",%s", namecodes[i].name);
else
nwritten = libdrv_snprintf(buf, NAMECODE_BUF_MAX, "%s", namecodes[i].name);
n_codes++;
}
n_codes++;
}
if (n_codes == 0)
libdrv_snprintf(buf, NAMECODE_BUF_MAX, "Unknown %s code: %x", codetype, code);
Expand Down

0 comments on commit 9623f29

Please sign in to comment.