]> git.sur5r.net Git - bacula/bacula/commitdiff
Cleanup BVFS cache when deleting a Job
authorEric Bollengier <eric@eb.homelinux.org>
Tue, 28 Sep 2010 17:03:08 +0000 (19:03 +0200)
committerEric Bollengier <eric@eb.homelinux.org>
Thu, 30 Sep 2010 12:35:28 +0000 (14:35 +0200)
bacula/src/dird/ua_purge.c

index 33adb4012bec98dbbf8f462e1fe67af7f0c2c3d7..bd0efcea7d66360fc1542bb85d28ae5eae7c1be1 100644 (file)
@@ -427,6 +427,9 @@ void purge_jobs_from_catalog(UAContext *ua, char *jobs)
    db_sql_query(ua->db, query.c_str(), NULL, (void *)NULL);
    Dmsg1(050, "Delete RestoreObject sql=%s\n", query.c_str());
 
+   Mmsg(query, "DELETE FROM PathVisibility WHERE JobId IN (%s)", jobs);
+   db_sql_query(ua->db, query.c_str(), NULL, (void *)NULL);
+   Dmsg1(050, "Delete PathVisibility sql=%s\n", query.c_str());
 
    upgrade_copies(ua, jobs);