Skip to content

Commit

Permalink
CS adjustments
Browse files Browse the repository at this point in the history
  • Loading branch information
terrafrost committed May 29, 2024
1 parent b686baf commit 7e21068
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 2 additions & 0 deletions phpseclib/Exception/InvalidPacketLengthException.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<?php

declare(strict_types=1);

namespace phpseclib3\Exception;

/**
Expand Down
3 changes: 1 addition & 2 deletions phpseclib/Net/SSH2.php
Original file line number Diff line number Diff line change
Expand Up @@ -1920,7 +1920,6 @@ private static function mac_algorithm_to_hash_instance(string $algorithm): ?arra
* @link https://www.chiark.greenend.org.uk/~sgtatham/putty/wishlist/ssh2-aesctr-openssh.html
* @link https://bugzilla.mindrot.org/show_bug.cgi?id=1291
* @param string $algorithm Name of the encryption algorithm
* @return bool
*/
private static function bad_algorithm_candidate($algorithm): bool
{
Expand Down Expand Up @@ -4040,7 +4039,7 @@ protected function send_binary_packet(string $data, ?string $logged = null): voi
/**
* Sends a keep-alive message, if keep-alive is enabled and interval is met
*/
private function send_keep_alive()
private function send_keep_alive(): void
{
$elapsed = microtime(true) - $this->keep_alive_sent;
if ($this->keepAlive > 0 && $elapsed >= $this->keepAlive) {
Expand Down
4 changes: 2 additions & 2 deletions tests/Functional/Net/SSH2Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -557,7 +557,7 @@ public function testReadingOfClosedChannel(): void
$this->assertSame(0, $ssh->getOpenChannelCount());
}

public function testPing()
public function testPing(): void
{
$ssh = $this->getSSH2();
// assert on unauthenticated ssh2
Expand Down Expand Up @@ -597,7 +597,7 @@ public static function getCryptoAlgorithms()
* @param string $type
* @param string $algorithm
*/
public function testCryptoAlgorithms($type, $algorithm)
public function testCryptoAlgorithms($type, $algorithm): void
{
$ssh = $this->getSSH2();
try {
Expand Down

0 comments on commit 7e21068

Please sign in to comment.