From 8d1a34dbdb43b6093c6717468f44dc249fa504ec Mon Sep 17 00:00:00 2001 From: root Date: Mon, 16 May 2005 23:08:31 +0200 Subject: [PATCH] [PATCH] call dm_lib_release/exit explicitly in multipath-tools multipath-tools should call dm_lib_release() and dm_lib_exit() before it returns. Then, libdevmapper will call update_devs() and finalize the device node operation which creates /dev/mapper/. This patch may not be needed if the latest libdevmapper of the device-mapper CVS is used, since in the latest version, dm_lib_exit() calls dm_lib_release() and dm_lib_exit() is called by default when the program returns. Regards, Kiyoshi Ueda --- kpartx/kpartx.c | 3 +++ multipath/main.c | 2 ++ 2 files changed, 5 insertions(+) diff --git a/kpartx/kpartx.c b/kpartx/kpartx.c index 5d714bf..cf7eda9 100644 --- a/kpartx/kpartx.c +++ b/kpartx/kpartx.c @@ -429,6 +429,9 @@ main(int argc, char **argv){ if (n > 0) break; } + dm_lib_release(); + dm_lib_exit(); + return 0; } diff --git a/multipath/main.c b/multipath/main.c index 5900cb6..e3c4c29 100644 --- a/multipath/main.c +++ b/multipath/main.c @@ -1004,6 +1004,8 @@ out: free_multipathvec(curmp, KEEP_PATHS); free_pathvec(pathvec, FREE_PATHS); free_config(conf); + dm_lib_release(); + dm_lib_exit(); #ifdef _DEBUG_ dbg_free_final(NULL); #endif -- 2.7.4