]> git.ipfire.org Git - thirdparty/snapper.git/commitdiff
improve error logging 789/head
authorArvin Schnell <aschnell@suse.de>
Wed, 22 Feb 2023 11:47:12 +0000 (12:47 +0100)
committerArvin Schnell <aschnell@suse.de>
Wed, 22 Feb 2023 11:47:12 +0000 (12:47 +0100)
snapper/Snapper.cc

index 3d8b4371d56bbea6127afff90de3bdbfa3c42f37..e76977b2e2dd2457eca480c6d7bdcad3552b59c7 100644 (file)
@@ -851,8 +851,15 @@ namespace snapper
        // Tests have shown that without a rescan and sync here the quota data
        // is incorrect.
 
-       quota_rescan(general_dir.fd());
-       sync(general_dir.fd());
+       try
+       {
+           quota_rescan(general_dir.fd());
+           sync(general_dir.fd());
+       }
+       catch (...)
+       {
+           SN_THROW(QuotaException("quota rescan or sync failed"));
+       }
 
        QuotaData quota_data;