Skip to content

ext/sockets: php_set_inet*_addr using zend_string instead. #17845

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

Merged
merged 1 commit into from
Feb 20, 2025

Conversation

devnexen
Copy link
Member

No description provided.

Copy link
Member

@Girgias Girgias left a comment

Choose a reason for hiding this comment

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

Looks sensible to me.

@@ -128,7 +128,7 @@ static zend_result php_get_address_from_array(const HashTable *ht, const char *k
return FAILURE;
}
str = zval_get_tmp_string(val, &tmp_str);
Copy link
Member

Choose a reason for hiding this comment

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

Follow-up PR: but this should use the try API.

@@ -605,7 +605,7 @@ static void from_zval_write_sin6_addr(const zval *zaddr_str, char *addr6, ser_co
zend_string *addr_str, *tmp_addr_str;

addr_str = zval_get_tmp_string((zval *) zaddr_str, &tmp_addr_str);
Copy link
Member

Choose a reason for hiding this comment

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

Ditto: try API.

Comment on lines 1670 to 1671
char *buf;
zend_string *addr;
Copy link
Member

Choose a reason for hiding this comment

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

I'm not sure the indent makes sense. Especially as the other ones are tab indented...

Suggested change
char *buf;
zend_string *addr;
char *buf;
zend_string *addr;

@devnexen devnexen force-pushed the socket_set_inet_zend_string branch from 60ca9b7 to 8cfbe50 Compare February 20, 2025 21:30
@devnexen devnexen merged commit 6c096bf into php:master Feb 20, 2025
9 checks passed
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