Skip to content

Commit

Permalink
Merge pull request #1167 from zevv/janet-formatbf-fix
Browse files Browse the repository at this point in the history
Fix janet_formatbv() type when handling %d %u int specifiers
  • Loading branch information
bakpakin authored May 29, 2023
2 parents 82e51f9 + e64a017 commit dbb2187
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/pp.c
Original file line number Diff line number Diff line change
Expand Up @@ -846,15 +846,15 @@ void janet_formatbv(JanetBuffer *b, const char *format, va_list args) {
}
case 'd':
case 'i': {
int64_t n = va_arg(args, long);
int64_t n = va_arg(args, int);
nb = snprintf(item, MAX_ITEM, form, n);
break;
}
case 'x':
case 'X':
case 'o':
case 'u': {
uint64_t n = va_arg(args, unsigned long);
uint64_t n = va_arg(args, unsigned int);
nb = snprintf(item, MAX_ITEM, form, n);
break;
}
Expand Down

0 comments on commit dbb2187

Please sign in to comment.