From 88f15ea5bcc548441e3b1f24c3b74e85c821d54d Mon Sep 17 00:00:00 2001 From: Marc Espie Date: Wed, 11 Nov 2009 12:59:35 +0000 Subject: remove extra warnings --- usr.sbin/pkg_add/OpenBSD/ArcCheck.pm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'usr.sbin/pkg_add') diff --git a/usr.sbin/pkg_add/OpenBSD/ArcCheck.pm b/usr.sbin/pkg_add/OpenBSD/ArcCheck.pm index 96c308fd646..0d243d8b4e8 100644 --- a/usr.sbin/pkg_add/OpenBSD/ArcCheck.pm +++ b/usr.sbin/pkg_add/OpenBSD/ArcCheck.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: ArcCheck.pm,v 1.13 2009/11/10 11:36:56 espie Exp $ +# $OpenBSD: ArcCheck.pm,v 1.14 2009/11/11 12:59:34 espie Exp $ # # Copyright (c) 2005-2006 Marc Espie # @@ -132,7 +132,8 @@ sub prepare_long $self->{name_index} = 0 if !defined $self->{name_index}; $entry->set_name('LongName'.$self->{name_index}++); } - if (length($entry->{linkname}) > MAXLINKNAME) { + if ((defined $entry->{linkname}) && + length($entry->{linkname}) > MAXLINKNAME) { $self->{linkname_index} = 0 if !defined $self->{linkname_index}; $entry->{linkname} = 'LongLink'.$self->{linkname_index}++; } -- cgit v1.2.3