Skip to contentSkip to conversation

LVM2 ./WHATS_NEW lib/commands/toolcontext.c

PATCH [email protected] 1 participant 1 message Jan 23, 2007

lore
Share & tools
lore
#0 lore raw

CVSROOT: /cvs/lvm2
Module name: LVM2
Changes by: agk at sourceware.org 2007-01-23 16:03:54

Modified files:
. : WHATS_NEW
lib/commands : toolcontext.c

Log message:
Long-lived processes write out persistent dev cache in refresh_toolcontext().

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/WHATS_NEW.diff?cvsroot=lvm2&r1=1.552&r2=1.553
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/commands/toolcontext.c.diff?cvsroot=lvm2&r1=1.44&r2=1.45

WHATS_NEW +1 -0
@@ -1,5 +1,6 @@
 Version 2.02.20 -
 ===================================
+  Long-lived processes write out persistent dev cache in refresh_toolcontext().
   Fix refresh_toolcontext() always to wipe persistent device filter cache.
   Add is_long_lived to toolcontext.
   Add --clustered to man pages.
lib/commands/toolcontext.c +7 -0
@@ -1080,6 +1080,13 @@
 	if (!_init_segtypes(cmd))
 		return 0;
 
+	/*
+	 * If we are a long-lived process, write out the updated persistent
+	 * device cache for the benefit of short-lived processes.
+	 */
+	if (cmd->is_long_lived && cmd->dump_filter)
+		persistent_filter_dump(cmd->filter);
+
 	cmd->config_valid = 1;
 	return 1;
 }