From 6b79a74601b57500ff786e1bb9f9ec94e72416ad Mon Sep 17 00:00:00 2001 From: Rodrigo Arias Mallo Date: Sun, 18 Feb 2024 16:04:48 +0100 Subject: Expand tilde to home directory in local URLs Allows paths like "file:~/" and "file:~/.dillo/dillorc" to be opened by Dillo by expanding the tilde character '~' to the value of the $HOME environment variable. Fixes: https://github.com/dillo-browser/dillo/issues/81 --- src/uicmd.cc | 2 -- 1 file changed, 2 deletions(-) (limited to 'src') diff --git a/src/uicmd.cc b/src/uicmd.cc index e153ba70..5eb64b7b 100644 --- a/src/uicmd.cc +++ b/src/uicmd.cc @@ -730,8 +730,6 @@ void a_UIcmd_open_urlstr(void *vbw, const char *urlstr) ch = new_urlstr[5]; if (!ch || ch == '.') { url = a_Url_new(Paths::getOldWorkingDir(), "file:"); - } else if (ch == '~') { - url = a_Url_new(dGethomedir(), "file:"); } else { url = a_Url_new(new_urlstr, "file:"); } -- cgit v1.2.3