Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix hex display: pad 01-0F values to two digits #356

Merged
merged 1 commit into from
Sep 26, 2024

Conversation

bungoume
Copy link
Contributor

  • Change format specifier from %X to %02X
  • Ensure values 01-0F are displayed with leading zero

Fixed this test.

declare local var.str STRING;

set var.str = urlencode("%01%02%03%04%05%06%07%08%09%0A%0B%0C%0D%0E%0F");
assert.equal(std.strlen(var.str), 45);
assert.equal(var.str, {"%01%02%03%04%05%06%07%08%09%0A%0B%0C%0D%0E%0F"});
Assertion Error
Assertion error: expect=45, actual=30
Assertion error: expect=%01%02%03%04%05%06%07%08%09%0A%0B%0C%0D%0E%0F, actual=%1%2%3%4%5%6%7%8%9%A%B%C%D%E%F

Copy link
Owner

@ysugimoto ysugimoto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah you're correct, thanks.

@ysugimoto ysugimoto merged commit 73b3ab8 into ysugimoto:main Sep 26, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants