Skip to content
This repository has been archived by the owner on Jun 1, 2023. It is now read-only.

Commit

Permalink
podcheck.t: no memory exhaustion
Browse files Browse the repository at this point in the history
skip slurping overlarge logfiles > 1MB,
e.g. valgrind logfiles, esp. on 32bit.
podcheck does not look at the filename extension
if it's a potential podfile.
  • Loading branch information
Reini Urban committed Jan 6, 2016
1 parent f3022ec commit 9ee3feb
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion t/porting/podcheck.t
Original file line number Diff line number Diff line change
Expand Up @@ -1371,7 +1371,12 @@ sub is_pod_file {
# Otherwise fail it here and no reason to process it further.
# (But the test count will be off too)
ok(0, "Can't open '$filename': $!")
if -r $filename && ! -l $filename;
if -r $filename && ! -l $filename;
return;
}
if (-s $filename > 1_000_000_000) {
# don't slurp >1MB logfiles
ok(0, "Skip overlarge '$filename': size=".(-s $filename));
return;
}
<$candidate>;
Expand Down

0 comments on commit 9ee3feb

Please sign in to comment.