summaryrefslogtreecommitdiff
path: root/program/lib/Net/Socket.php
diff options
context:
space:
mode:
Diffstat (limited to 'program/lib/Net/Socket.php')
-rw-r--r--program/lib/Net/Socket.php11
1 files changed, 3 insertions, 8 deletions
diff --git a/program/lib/Net/Socket.php b/program/lib/Net/Socket.php
index bf1d1bbcd..a67a11af1 100644
--- a/program/lib/Net/Socket.php
+++ b/program/lib/Net/Socket.php
@@ -672,15 +672,10 @@ class Net_Socket extends PEAR
*/
function enableCrypto($enabled, $type)
{
- if (version_compare(phpversion(), "5.1.0", ">=")) {
- if (!is_resource($this->fp)) {
- return $this->raiseError('not connected');
- }
- return @stream_socket_enable_crypto($this->fp, $enabled, $type);
- } else {
- $msg = 'Net_Socket::enableCrypto() requires php version >= 5.1.0';
- return $this->raiseError($msg);
+ if (!is_resource($this->fp)) {
+ return $this->raiseError('not connected');
}
+ return @stream_socket_enable_crypto($this->fp, $enabled, $type);
}
}