Skip to content
This repository has been archived by the owner on Oct 23, 2019. It is now read-only.

curl_setopt does not allow an empty string value as an array value #48

Open
ghost opened this issue Mar 30, 2015 · 1 comment
Open

curl_setopt does not allow an empty string value as an array value #48

ghost opened this issue Mar 30, 2015 · 1 comment

Comments

@ghost
Copy link

ghost commented Mar 30, 2015

I was trying to pass in an array of key value pairs with curl_setopt with CurlOption = CURLOPT_POSTFIELDS. One of my array values was an empty string. I debugged the code to CurlForm.Create. The first character in the string is compared to "@" to determine if the array needs to be treated as a file (per the comment). But the string is not first checked to determine if the length of the string is >= 1. The PHP run-time allows for an empty string, so the Phalanger Curl extensions should too. I also need to test the possibility of a null value in the run-time so that Phalanger's behavior is exactly the same as the official PHP run-time. I will do a pull request tonight or tomorrow night and fix this issue.

@bfistein
Copy link
Contributor

@sdegenhardt13 Phalanger's development is mostly discontinued in favor of PeachPie, the more modern compiler and runtime that also targets .NET Core. Please feel free to give that a try.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant