Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[stable30] Fix remaining readdir() calls in loops with undesirable false evaluation potential #49241

Merged
merged 2 commits into from
Nov 13, 2024

Conversation

backportbot[bot]
Copy link

@backportbot backportbot bot commented Nov 13, 2024

Backport of #38630

Warning, This backport's changes differ from the original and might be incomplete ⚠️

Todo

  • Review and resolve any conflicts
  • Amend HEAD commit to remove the line stating to skip CI

Learn more about backports at https://docs.nextcloud.com/server/stable/go.php?to=developer-backports.

@yemkareems yemkareems force-pushed the backport/38630/stable30 branch from 230d2e4 to 3b33646 Compare November 13, 2024 03:43
@yemkareems yemkareems requested a review from susnux November 13, 2024 03:44
@yemkareems yemkareems marked this pull request as ready for review November 13, 2024 03:44
@@ -228,7 +228,7 @@
}

$dh = $this->opendir($path);
while ($file = readdir($dh)) {
while (($file = readdir($dh)) !== false) {

Check notice

Code scanning / Psalm

PossiblyFalseArgument Note

Argument 1 of readdir cannot be false, possibly resource value expected
@@ -494,7 +494,7 @@
}

$dh = $this->opendir($source);
while ($file = readdir($dh)) {
while (($file = readdir($dh)) !== false) {

Check notice

Code scanning / Psalm

PossiblyFalseArgument Note

Argument 1 of readdir cannot be false, possibly resource value expected
@yemkareems yemkareems enabled auto-merge November 13, 2024 03:58
@yemkareems yemkareems merged commit 56ce5d0 into stable30 Nov 13, 2024
177 checks passed
@yemkareems yemkareems deleted the backport/38630/stable30 branch November 13, 2024 09:46
@skjnldsv skjnldsv mentioned this pull request Nov 27, 2024
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants