]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/lib/jcr.c
Working directory pane in restore. Will get this into the stack next.
[bacula/bacula] / bacula / src / lib / jcr.c
index 982f4d0a9b37f3cf3434781ffaf7fdf61fdcf27d..925227a6b66ff45c621f1290da2c207ced19b792 100644 (file)
@@ -56,6 +56,9 @@
 /* External variables we reference */
 extern time_t watchdog_time;
 
+/* External referenced functions */
+void free_bregexps(alist *bregexps);
+
 /* Forward referenced functions */
 extern "C" void timeout_handler(int sig);
 static void jcr_timeout_check(watchdog_t *self);
@@ -381,6 +384,15 @@ static void free_common_jcr(JCR *jcr)
       free(jcr->where);
       jcr->where = NULL;
    }
+   if (jcr->RegexWhere) {
+      free(jcr->RegexWhere);
+      jcr->RegexWhere = NULL;
+   }
+   if (jcr->where_bregexp) {
+      free_bregexps(jcr->where_bregexp);
+      delete jcr->where_bregexp;
+      jcr->where_bregexp = NULL;
+   }
    if (jcr->cached_path) {
       free_pool_memory(jcr->cached_path);
       jcr->cached_path = NULL;