mirror of
https://github.com/curl/curl.git
synced 2026-04-17 10:51:41 +03:00
Previously, the return code CURLUE_MALFORMED_INPUT was used for almost 30 different URL format violations. This made it hard for users to understand why a particular URL was not acceptable. Since the API cannot point out a specific position within the URL for the problem, this now instead introduces a number of additional and more fine-grained error codes to allow the API to return more exactly in what "part" or section of the URL a problem was detected. Also bug-fixes curl_url_get() with CURLUPART_ZONEID, which previously returned CURLUE_OK even if no zoneid existed. Test cases in 1560 have been adjusted and extended. Tests 1538 and 1559 have been updated. Updated libcurl-errors.3 and curl_url_strerror() accordingly. Closes #8049
44 lines
712 B
Text
44 lines
712 B
Text
<testcase>
|
|
<info>
|
|
<keywords>
|
|
CURLOPT_URL
|
|
</keywords>
|
|
</info>
|
|
|
|
<reply>
|
|
</reply>
|
|
|
|
<client>
|
|
<server>
|
|
none
|
|
</server>
|
|
|
|
# require HTTP so that CURLOPT_POSTFIELDS works as assumed
|
|
<features>
|
|
http
|
|
</features>
|
|
<tool>
|
|
lib%TESTNUMBER
|
|
</tool>
|
|
|
|
<name>
|
|
Set excessive URL lengths
|
|
</name>
|
|
</client>
|
|
|
|
#
|
|
# Verify that the test runs to completion without crashing
|
|
<verify>
|
|
<errorcode>
|
|
0
|
|
</errorcode>
|
|
<stdout>
|
|
CURLOPT_URL 10000000 bytes URL == 43
|
|
CURLOPT_POSTFIELDS 10000000 bytes data == 0
|
|
CURLUPART_URL 10000000 bytes URL == 3 (Malformed input to a URL function)
|
|
CURLUPART_SCHEME 10000000 bytes scheme == 27 (Bad scheme)
|
|
CURLUPART_USER 10000000 bytes user == 3 (Malformed input to a URL function)
|
|
</stdout>
|
|
</verify>
|
|
|
|
</testcase>
|