From 99f7810d1034b057f77bec4ae57ec080992ad9a9 Mon Sep 17 00:00:00 2001 From: Leonardo Taccari Date: Mon, 15 Oct 2018 17:29:13 +0200 Subject: [PATCH] Document a subtlety of util_parse_expansion() behaviour. Single ~ uses g_get_home_dir() that honor HOME environment variable. However, ~user always consult the passwd file. --- src/util.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/util.c b/src/util.c index 5844ff7..dbce2a0 100644 --- a/src/util.c +++ b/src/util.c @@ -678,6 +678,10 @@ double util_js_result_as_number(WebKitJavascriptResult *result) * not expanded char. If no expansion pattern was found, the first char is * appended to given GString. * + * Please note that for a single ~, g_get_home_dir() is used and if a valid + * HOME environment variable is set it is preferred than passwd file. + * However, for ~user expansion the passwd file is always used. + * * @input: String pointer with the content to be parsed. * @str: GString that will be filled with expanded content. * @flags Flags that determine which expansion are processed. -- 2.20.1