From 635e7e0c928aba62f7d6ddf892978ece6217b905 Mon Sep 17 00:00:00 2001 From: Zdenek Kabelac Date: Sat, 1 Apr 2017 12:13:37 +0200 Subject: [PATCH] libdm: set min,maj Reset derefered pointers instead of pointers. --- WHATS_NEW_DM | 1 + libdm/libdm-deptree.c | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/WHATS_NEW_DM b/WHATS_NEW_DM index 23f3ce5f0..2fa2566ea 100644 --- a/WHATS_NEW_DM +++ b/WHATS_NEW_DM @@ -1,5 +1,6 @@ Version 1.02.139 - ================================== + Fix assignment in _target_version() when dm task can't run. Flush stdout on each iteration when using --count or --interval. Show detailed error message when execvp fails while starting dmfilemapd. Fix segmentation fault when dmfilemapd is run with no arguments. diff --git a/libdm/libdm-deptree.c b/libdm/libdm-deptree.c index 80bfc1be7..6ea710def 100644 --- a/libdm/libdm-deptree.c +++ b/libdm/libdm-deptree.c @@ -2400,9 +2400,8 @@ static int _target_version(const char *target_name, uint32_t *maj, if (!dm_task_run(dmt)) { log_debug_activation("Failed to get %s target versions", target_name); /* Assume this was because LIST_VERSIONS isn't supported */ - maj = min = patchlevel = 0; + *maj = *min = *patchlevel = 0; r = 1; - } else for (target = dm_task_get_versions(dmt); target != last_target;