From b8ceb96bd45057ba077183f04f01ed150ad73f03 Mon Sep 17 00:00:00 2001 From: terrafrost Date: Wed, 1 Mar 2017 22:14:58 -0600 Subject: [PATCH] SSH2: include
 tags in getLog result when SAPI isn't CLI

---
 phpseclib/Net/SSH2.php | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/phpseclib/Net/SSH2.php b/phpseclib/Net/SSH2.php
index c1eb81d7..d8afa895 100644
--- a/phpseclib/Net/SSH2.php
+++ b/phpseclib/Net/SSH2.php
@@ -3984,8 +3984,8 @@ class Net_SSH2
                 return $this->message_number_log;
                 break;
             case NET_SSH2_LOG_COMPLEX:
-                return $this->_format_log($this->message_log, $this->message_number_log);
-                break;
+                $log = $this->_format_log($this->message_log, $this->message_number_log);
+                return PHP_SAPI == 'cli' ? $log : '
' . $log . '
'; default: return false; }