Closed
Conversation
nikic
reviewed
Aug 26, 2018
ext/standard/ftp_fopen_wrapper.c
Outdated
| int8_t read_write = 0; | ||
| char *transport; | ||
| int transport_len; | ||
| zend_string *error_message; |
Member
There was a problem hiding this comment.
Looks like php_stream_xport_create() does not NULL this variable out, so it will need a NULL initialization here.
Member
There was a problem hiding this comment.
Even if php_stream_xport_create() did the null initialization, we'd still need the =NULL here, because an error might occur prior to the php_stream_xport_create() call. An alternative would be to move the error_string handling directly into the failure branch of the php_stream_xport_create() call, rather than having it in errexit. Either way should be fine.
Contributor
Author
There was a problem hiding this comment.
That's correct, NULL initialization is required. That has been fixed now.
nikic
reviewed
Aug 26, 2018
ext/standard/ftp_fopen_wrapper.c
Outdated
| if (error_message) { | ||
| php_stream_wrapper_log_error(wrapper, options, "Failed to set up data channel: %s", ZSTR_VAL(error_message)); | ||
| zend_string_release(error_message); | ||
| } |
nikic
approved these changes
Aug 29, 2018
Member
|
Merged as 742783c into 7.1+. Thanks! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bug #73457