libuv 1.48.0.

git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4828 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
2024-02-07 23:12:32 +00:00
parent e98802f5b2
commit 6765254f43
53 changed files with 1172 additions and 305 deletions

View File

@@ -100,6 +100,7 @@ TEST_IMPL(utf8_decode1) {
TEST_IMPL(utf8_decode1_overrun) {
const char* p;
char b[1];
char c[1];
/* Single byte. */
p = b;
@@ -113,6 +114,10 @@ TEST_IMPL(utf8_decode1_overrun) {
ASSERT_EQ((unsigned) -1, uv__utf8_decode1(&p, b + 1));
ASSERT_PTR_EQ(p, b + 1);
b[0] = 0x7F;
ASSERT_EQ(UV_EINVAL, uv__idna_toascii(b, b + 0, c, c + 1));
ASSERT_EQ(UV_EINVAL, uv__idna_toascii(b, b + 1, c, c + 1));
return 0;
}
@@ -146,8 +151,8 @@ TEST_IMPL(idna_toascii) {
/* Illegal inputs. */
F("\xC0\x80\xC1\x80", UV_EINVAL); /* Overlong UTF-8 sequence. */
F("\xC0\x80\xC1\x80.com", UV_EINVAL); /* Overlong UTF-8 sequence. */
F("", UV_EINVAL);
/* No conversion. */
T("", "");
T(".", ".");
T(".com", ".com");
T("example", "example");