diff options
author | Marc Espie <espie@cvs.openbsd.org> | 2005-08-05 10:03:11 +0000 |
---|---|---|
committer | Marc Espie <espie@cvs.openbsd.org> | 2005-08-05 10:03:11 +0000 |
commit | aaceede11b63459d859377f46124585c7e967378 (patch) | |
tree | e49aded91e75b5a96c047cf38b1e38aee858a9cf | |
parent | fa5dac37e1486270add9b3c1ec82be160a517f20 (diff) |
activate sanity check: only files have !0 size.
-rw-r--r-- | usr.sbin/pkg_add/OpenBSD/Ustar.pm | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/Ustar.pm b/usr.sbin/pkg_add/OpenBSD/Ustar.pm index d5576a48535..8417e254111 100644 --- a/usr.sbin/pkg_add/OpenBSD/Ustar.pm +++ b/usr.sbin/pkg_add/OpenBSD/Ustar.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: Ustar.pm,v 1.32 2005/08/05 10:01:38 espie Exp $ +# $OpenBSD: Ustar.pm,v 1.33 2005/08/05 10:03:10 espie Exp $ # # Copyright (c) 2002-2004 Marc Espie <espie@openbsd.org> # @@ -152,11 +152,11 @@ sub next } else { die "Unsupported type"; } -# if (!$result->isFile()) { -# if ($size != 0) { -# die "Bad archive: non null size for non file entry\n"; -# } -# } + if (!$result->isFile()) { + if ($size != 0) { + die "Bad archive: non null size for non file entry\n"; + } + } # adjust swallow $self->{swallow} = $size; if ($size % 512) { |