From 7bbdec13fd374f99ef9ec04c2824e3b1e635a454 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Grubbstr=C3=B6m=20=28Grubba=29?= <grubba@grubba.org> Date: Thu, 7 Aug 2014 15:01:02 +0200 Subject: [PATCH] SSL.File: Removed some redundant tests in read(). --- lib/modules/SSL.pmod/File.pike | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/modules/SSL.pmod/File.pike b/lib/modules/SSL.pmod/File.pike index 6028b1119f..ff68599c1e 100644 --- a/lib/modules/SSL.pmod/File.pike +++ b/lib/modules/SSL.pmod/File.pike @@ -823,8 +823,8 @@ string read (void|int length, void|int(0..1) not_all) !(conn->state & CONNECTION_peer_down), 0); } else { - if (sizeof (read_buffer) < length || zero_type (length)) - RUN_MAYBE_BLOCKING ((sizeof (read_buffer) < length || zero_type (length)) && + if (sizeof (read_buffer) < length) + RUN_MAYBE_BLOCKING ((sizeof (read_buffer) < length) && !(conn->state & CONNECTION_peer_down), nonblocking_mode); } -- GitLab