Skip to content

Commit 7d6e5a3

Browse files
committed
Remove debugging traps
1 parent ed701fb commit 7d6e5a3

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

MooseFSPlugin.pm

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -15,26 +15,6 @@ use PVE::ProcFSTools;
1515

1616
use base qw(PVE::Storage::Plugin);
1717

18-
# Debugging traps, to eventually be removed
19-
use Carp;
20-
21-
BEGIN {
22-
$SIG{__DIE__} = sub {
23-
my $msg = shift;
24-
if ($msg =~ /Can't use string \(.*\) as a HASH ref/) {
25-
my $ts = POSIX::strftime('%Y-%m-%d %H:%M:%S', localtime);
26-
open my $fh, '>>', '/var/log/mfsplugindebug.log';
27-
print $fh "$ts: Caught HASH ref crash: $msg\n";
28-
print $fh "$ts: Stack trace:\n";
29-
local $Carp::CarpLevel = 1;
30-
print $fh Carp::longmess("STACK:\n");
31-
close $fh;
32-
}
33-
die $msg;
34-
};
35-
}
36-
# End debugging traps
37-
3818
# Logging function, called only when needed explicitly
3919
sub log_debug {
4020
my ($msg) = @_;
@@ -679,10 +659,6 @@ sub filesystem_path {
679659
}
680660

681661
my $ts = POSIX::strftime('%Y-%m-%d %H:%M:%S', localtime);
682-
log_debug("[filesystem_path] TRACE triggered at $ts");
683-
log_debug("[filesystem_path] scfg type: " . ref($scfg));
684-
log_debug("[filesystem_path] volname: $volname");
685-
log_debug("[filesystem_path] backtrace:\n" . longmess("[filesystem_path]"));
686662

687663
my ($vtype, $name, $vmid, undef, undef, $isBase, $format) = $class->parse_volname($volname);
688664

0 commit comments

Comments
 (0)