scstadmin: Fix a Perl warning

git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@9159 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Bart Van Assche
2020-09-14 18:00:55 +00:00
parent 6d60231631
commit 4023bdadbd

View File

@@ -494,7 +494,11 @@ sub setScstAttribute {
return TRUE if (!length($attribute) || !defined($value));
my $bytes = -ENOENT;
# There is a space between the unary minus sign and ENOENT because
# without that space older Perl versions report the following warning:
# Ambiguous use of -ENOENT resolved as -&ENOENT() at
# /usr/share/perl5/vendor_perl/SCST/SCST.pm line 497.
my $bytes = - ENOENT;
my $path = make_path(SCST_ROOT_DIR(), $attribute);
my $io = new IO::File $path, O_WRONLY;
if ($io) {