Skip to content

Conversation

@datibbaw
Copy link
Contributor

This fixes bug 66109 and addresses this so question.

It allows for a NULL value to be passed for CURLOPT_CUSTOMREQUEST, so that the internal behaviour can be reset.

The following string options are nullable as well:

CURLOPT_FTPPORT
CURLOPT_FTP_ACCOUNT
CURLOPT_RTSP_SESSION_ID
CURLOPT_RANGE
CURLOPT_KRBLEVEL

And for 7.33 onwards, these may be added as well:

CURLOPT_DNS_INTERFACE
CURLOPT_DNS_LOCAL_IP4
CURLOPT_DNS_LOCAL_IP6

Copy link
Contributor

Choose a reason for hiding this comment

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

what happened to indentation here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yikes. Indentation fail.

Choose a reason for hiding this comment

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

Die Zustellung an folgende Empfänger oder Gruppen verzögert sich:

p.bandow@justepic.infomailto:p.bandow@justepic.info

Betreff: Re: [php-src] Allow NULL as value for CURLOPT_CUSTOMREQUEST option. (#531)

Diese Nachricht wurde noch nicht zugestellt. Es wird weiterhin versucht, die Nachricht zuzustellen.

Der Server wird noch 2 Tage, 22 Stunden und 52 Minuten versuchen, die Nachricht zuzustellen. Sie erhalten eine Benachrichtigung, falls die Nachricht bis dahin nicht übermittelt werden konnte.

@datibbaw
Copy link
Contributor Author

@smalyshev I've made the change to php_curl_option_str() like you proposed; it looks a lot nicer now :)

Added test case.

Refactored the code to isolate the string handling. Fixed return values to use SUCCESS and FAILURE.

Removed unused error variable.

Indentation fix.
Removed the ugly goto.
@php-pulls
Copy link

Comment on behalf of datibbaw at php.net:

Merged into 5.5, 5.6 and master.

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.

4 participants