File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -1773,7 +1773,7 @@ PHP_FUNCTION(socket_sendto)
17731773 RETURN_THROWS();
17741774 }
17751775
1776- memset(&sll, 0, sizeof(sll));
1776+ memset(&sll, 0, sizeof(sll));
17771777 sll.sll_family = AF_PACKET;
17781778 sll.sll_ifindex = port;
17791779
@@ -2331,16 +2331,17 @@ PHP_FUNCTION(socket_set_option)
23312331
23322332#if defined(TCP_USER_TIMEOUT )
23332333 case TCP_USER_TIMEOUT : {
2334- ov = zval_get_long (arg4 );
2334+ zval timeout = zval_get_long (arg4 );
23352335
23362336 // TCP_USER_TIMEOUT unsigned int
23372337 if (ZEND_LONG_UINT_OVFL (ov )) {
23382338 zend_argument_value_error (4 , "must be of between 0 and %u" , UINT_MAX );
23392339 RETURN_THROWS ();
23402340 }
23412341
2342- optlen = sizeof (ov );
2343- opt_ptr = & ov ;
2342+ unsigned int val = (unsigned int )timeout ;
2343+ optlen = sizeof (val );
2344+ opt_ptr = & val ;
23442345 break ;
23452346 }
23462347#endif
You can’t perform that action at this time.
0 commit comments