File: 0002-phpcbf-run.patch

package info (click to toggle)
phpseclib 1.0.24-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 2,940 kB
  • sloc: php: 11,795; sh: 66; xml: 50; makefile: 21
file content (81 lines) | stat: -rw-r--r-- 2,866 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
From: =?utf-8?q?David_Pr=C3=A9vot?= <taffit@debian.org>
Date: Mon, 11 Mar 2019 21:29:32 -1000
Subject: phpcbf run

Forwarded: no
---
 phpseclib/Net/SFTP.php                        |  1 -
 tests/Functional/Net/SCPSSH2UserStoryTest.php |  6 +++---
 tests/Functional/Net/SFTPUserStoryTest.php    | 11 ++++++-----
 tests/make_compatible_with_phpunit9.php       |  2 +-
 4 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/phpseclib/Net/SFTP.php b/phpseclib/Net/SFTP.php
index c4741d2..98c6056 100644
--- a/phpseclib/Net/SFTP.php
+++ b/phpseclib/Net/SFTP.php
@@ -2452,7 +2452,6 @@ class Net_SFTP extends Net_SSH2
                 fseek($fp, $offset);
                 $size-= $offset;
             }
-
         } elseif ($dataCallback) {
             $size = 0;
         } else {
diff --git a/tests/Functional/Net/SCPSSH2UserStoryTest.php b/tests/Functional/Net/SCPSSH2UserStoryTest.php
index 4ba69f1..0837f4b 100644
--- a/tests/Functional/Net/SCPSSH2UserStoryTest.php
+++ b/tests/Functional/Net/SCPSSH2UserStoryTest.php
@@ -8,9 +8,9 @@
 
 class Functional_Net_SCPSSH2UserStoryTest extends PhpseclibFunctionalTestCase
 {
-    static protected $remoteFile;
-    static protected $exampleData;
-    static protected $exampleDataLength;
+    protected static $remoteFile;
+    protected static $exampleData;
+    protected static $exampleDataLength;
 
     public static function setUpBeforeClass()
     {
diff --git a/tests/Functional/Net/SFTPUserStoryTest.php b/tests/Functional/Net/SFTPUserStoryTest.php
index 5407813..109564f 100644
--- a/tests/Functional/Net/SFTPUserStoryTest.php
+++ b/tests/Functional/Net/SFTPUserStoryTest.php
@@ -8,10 +8,10 @@
 
 class Functional_Net_SFTPUserStoryTest extends PhpseclibFunctionalTestCase
 {
-    static protected $scratchDir;
-    static protected $exampleData;
-    static protected $exampleDataLength;
-    static protected $buffer;
+    protected static $scratchDir;
+    protected static $exampleData;
+    protected static $exampleDataLength;
+    protected static $buffer;
 
     public static function setUpBeforeClass()
     {
@@ -788,7 +788,8 @@ class Functional_Net_SFTPUserStoryTest extends PhpseclibFunctionalTestCase
     public function testCallableGetWithLength($sftp)
     {
         $sftp->put('test.txt', 'zzzzz');
-        $sftp->get('test.txt', function($data) {}, 0, 1);
+        $sftp->get('test.txt', function ($data) {
+        }, 0, 1);
         $this->assertTrue(true);
     }
 }
diff --git a/tests/make_compatible_with_phpunit9.php b/tests/make_compatible_with_phpunit9.php
index 1e066b7..651e508 100644
--- a/tests/make_compatible_with_phpunit9.php
+++ b/tests/make_compatible_with_phpunit9.php
@@ -32,4 +32,4 @@ foreach ($files as $file) {
             throw new \RuntimeException('file_put_contents() failed: ' . $file->getPathname());
         }
     }
-}
\ No newline at end of file
+}