From c84face8ceec82123a5d4ecc309ab9bb7fbbfddf Mon Sep 17 00:00:00 2001 From: Peter Rajnoha Date: Mon, 24 Mar 2014 16:47:08 +0100 Subject: [PATCH] libdaemon: fix misleading "WARNING: Ignoring unsupported value for expected." when communicating with daemon When we're trying to search for certain tree node in daemon's reply, we default to a blank string "" if the node is not found. This happens during lvmetad initialization. However, when the default blank string is used, we can't use dm_config_find_str at the same time - the dm_config_find_str_allow_empty should be used instead. Otherwise a a warning message: "WARNING: Ignoring unsupported value for ..." is issued. --- libdaemon/client/daemon-client.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libdaemon/client/daemon-client.h b/libdaemon/client/daemon-client.h index 6ba65e6c7..8a44f8b71 100644 --- a/libdaemon/client/daemon-client.h +++ b/libdaemon/client/daemon-client.h @@ -102,7 +102,7 @@ static inline int64_t daemon_reply_int(daemon_reply r, const char *path, int64_t } static inline const char *daemon_reply_str(daemon_reply r, const char *path, const char *def) { - return dm_config_find_str(r.cft->root, path, def); + return dm_config_find_str_allow_empty(r.cft->root, path, def); }