diff options
Diffstat (limited to 'net-mgmt/nfsen-devel/files/patch-libexec_NfSen.pm')
-rw-r--r-- | net-mgmt/nfsen-devel/files/patch-libexec_NfSen.pm | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/net-mgmt/nfsen-devel/files/patch-libexec_NfSen.pm b/net-mgmt/nfsen-devel/files/patch-libexec_NfSen.pm new file mode 100644 index 000000000000..875b98ce0f55 --- /dev/null +++ b/net-mgmt/nfsen-devel/files/patch-libexec_NfSen.pm @@ -0,0 +1,53 @@ + +$FreeBSD$ + +--- libexec/NfSen.pm.orig ++++ libexec/NfSen.pm +@@ -705,6 +705,25 @@ + + } # End of LoadHints + ++sub LoadHints_startup { ++ ++ eval { ++ local $SIG{'__DIE__'} = 'DEFAULT'; ++ $hints = lock_retrieve "$NfConf::PROFILESTATDIR/hints"; ++ }; ++ ++ if ( my $err = $@ ) { ++ warn "Error reading hints: $err\n"; ++ warn "Initialize hints to defaults.\n"; ++ $$hints{'version'} = -1; # unknown ++ $$hints{'installed'} = 0; ++ $$hints{'subdirlayout'} = $NfConf::SUBDIRLAYOUT; ++ } ++ ++ return \$hints; ++ ++} # End of LoadHints_startup ++ + sub StoreHints { + + eval { +@@ -717,6 +736,20 @@ + return $err; + } + +-} # End of StoreAlertStatus ++} # End of StoreHints ++ ++sub StoreHints_startup { ++ ++ eval { ++ local $SIG{'__DIE__'} = 'DEFAULT'; ++ lock_store $hints, "$NfConf::PROFILESTATDIR/hints"; ++ }; ++ ++ if ( my $err = $@ ) { ++ warn "Error store hints: $err\n"; ++ return $err; ++ } ++ ++} # End of StoreHints_startup + + 1; |