summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr.sbin/pkg_add/OpenBSD/PkgCreate.pm9
1 files changed, 7 insertions, 2 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/PkgCreate.pm b/usr.sbin/pkg_add/OpenBSD/PkgCreate.pm
index edc5895849c..6938c0944b8 100644
--- a/usr.sbin/pkg_add/OpenBSD/PkgCreate.pm
+++ b/usr.sbin/pkg_add/OpenBSD/PkgCreate.pm
@@ -1,6 +1,6 @@
#! /usr/bin/perl
# ex:ts=8 sw=4:
-# $OpenBSD: PkgCreate.pm,v 1.25 2010/10/25 18:00:10 espie Exp $
+# $OpenBSD: PkgCreate.pm,v 1.26 2010/10/25 21:33:15 espie Exp $
#
# Copyright (c) 2003-2010 Marc Espie <espie@openbsd.org>
#
@@ -157,7 +157,12 @@ sub compute_checksum
if (defined $base) {
$fname = $base.$fname;
}
-
+ for my $field (qw(symlink link size)) { # md5
+ if (defined $result->{$field}) {
+ $state->error("User tried to define @#1 for #2",
+ $field, $fname);
+ }
+ }
if (-l $fname) {
if (!defined $base) {
$state->error("special file #1 can't be a symlink",