From e4d04d01b5c806f31bba510527e6600fbf4161a0 Mon Sep 17 00:00:00 2001 From: Wichert Akkerman Date: Thu, 30 Nov 2000 02:40:38 +0000 Subject: [PATCH] Fix ENOENT issues --- scripts/dpkg-statoverride.pl | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/scripts/dpkg-statoverride.pl b/scripts/dpkg-statoverride.pl index 90b4267d..6b20e431 100755 --- a/scripts/dpkg-statoverride.pl +++ b/scripts/dpkg-statoverride.pl @@ -1,5 +1,8 @@ #! /usr/bin/perl +use POSIX; +use POSIX qw(:errno_h :signal_h); + $admindir= "/var/lib/dpkg"; # This line modified by Makefile $version= '1.3.0'; # This line modified by Makefile @@ -213,9 +216,9 @@ sub WriteOverrides { close(SO); chmod(0644, "$admindir/statoverride-new"); unlink("$admindir/statoverride-old") || - $! == &ENOENT || &quit("error removing statoverride-old: $!"); + $! == ENOENT || &quit("error removing statoverride-old: $!"); link("$admindir/statoverride","$admindir/statoverride-old") || - $! == &ENOENT || &quit("error creating new statoverride-old: $!"); + $! == ENOENT || &quit("error creating new statoverride-old: $!"); rename("$admindir/statoverride-new","$admindir/statoverride") || &quit("error installing new statoverride: $!"); } -- 2.39.5