Skip to content

Fix multi-same-name-fields in Curl for old (> 7.56.0) versions #8460

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

Closed
wants to merge 2 commits into from

Conversation

derickr
Copy link
Member

@derickr derickr commented Apr 29, 2022

No description provided.

@cmb69
Copy link
Member

cmb69 commented Apr 29, 2022

While ext/curl now compiles for me (using curl 7.52.1), curl_postfields_array.phpt fails with:

     POST /get.inc?test=raw HTTP/1.1
     Host: %s
     Accept: */*
005+ Expect: 100-continue
     Content-Type: multipart/form-data; boundary=------------------------%s
006- 
007- --------------------------%s
008- Content-Disposition: form-data; name="single"
009- 
010- SingleValue
011- --------------------------%s
012- Content-Disposition: form-data; name="multi"
013- 
014- Multi1
015- --------------------------%s
016- Content-Disposition: form-data; name="multi"
017- 
018- Multi2
019- --------------------------%s--

@derickr
Copy link
Member Author

derickr commented Apr 29, 2022

Ah, that didn't run locally:

SKIP CURLOPT_POSTFIELDS with multi-value fields [ext/curl/tests/curl_postfields_array.phpt] reason: Required extension missing: sockets

Without this explicitly set, curl might decide to add a
`Expect: 100-continue` header if it deems the request too large.
See also: https://gms.tf/when-curl-sends-100-continue.html
derickr added a commit that referenced this pull request Apr 29, 2022
@derickr
Copy link
Member Author

derickr commented Apr 29, 2022

Merged, so closing.

@derickr derickr closed this Apr 29, 2022
@derickr derickr deleted the old-curl-fix branch April 29, 2022 15:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants