You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/* {{{ proto void ssh2_session_set_timeout(resource session, long milliseconds)
456
+
* Set the timeout in milliseconds for how long a blocking the libssh2 function calls may wait until they consider the situation an error and return LIBSSH2_ERROR_TIMEOUT.
457
+
*
458
+
* By default or if you set the timeout to zero, libssh2 has no timeout for blocking functions.
459
+
*/
460
+
PHP_FUNCTION(ssh2_session_set_timeout)
461
+
{
462
+
LIBSSH2_SESSION*session;
463
+
zval*zsession;
464
+
zend_longtimeout;
465
+
466
+
if (zend_parse_parameters(ZEND_NUM_ARGS(), "rl", &zsession, &timeout) ==FAILURE) {
467
+
return;
468
+
}
469
+
470
+
if ((session= (LIBSSH2_SESSION*)zend_fetch_resource(Z_RES_P(zsession), PHP_SSH2_SESSION_RES_NAME, le_ssh2_session)) ==NULL) {
471
+
return;
472
+
}
473
+
474
+
libssh2_session_set_timeout(session, timeout);
475
+
}
476
+
/* }}} */
477
+
455
478
/* {{{ proto array ssh2_methods_negotiated(resource session)
0 commit comments