X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=sysdump;h=e83738b4cf6cbd80a978b102675a0f533ede066d;hb=2a46773d300c03855b713abd9bde350ef2a48194;hp=1fd3e0ee545450d84fa653e1c06c5c23ec05ea89;hpb=89b71f0a569a8347159a5a8a434ac9ad3c9e637f;p=grml-hwinfo.git diff --git a/sysdump b/sysdump index 1fd3e0e..e83738b 100755 --- a/sysdump +++ b/sysdump @@ -62,7 +62,19 @@ sub dump_value($$) my $level = shift; my $file = shift; - open (FILE, "<$file") || die "can't open $file: $!"; + if ($file =~ "/sys/kernel/debug/.*") { + print("ignoring file $file\n"); + return 0; + } + if ($file =~ "/sys/kernel/security/apparmor/revision") { + print("ignoring file $file\n"); + return 0; + } + + if (!open (FILE, "<$file")) { + print STDERR "can't open $file: '$!'\n"; + return 0; + } my $value; { local $/;