added check to make sure /var/cache/sanoidsnapshots.txt is writeable

This commit is contained in:
Jim Salter 2014-11-18 09:49:24 -05:00
parent d30fbbef9a
commit b17c736928
1 changed files with 1 additions and 1 deletions

2
sanoid
View File

@ -464,7 +464,7 @@ sub getsnaps {
@rawsnaps = <FH>;
close FH;
open FH, "> $cache";
open FH, "> $cache" or die 'Could not write to $cache!\n';
print FH @rawsnaps;
close FH;
removelock('sanoid_cacheupdate');