From 00db99137212db66caa83d685824a74e984377ed Mon Sep 17 00:00:00 2001 From: Slava Zanko Date: Tue, 26 Jul 2011 11:49:33 +0300 Subject: [PATCH] FISH: Fixed creating relative symlinks Signed-off-by: Slava Zanko --- src/vfs/fish/fish.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/vfs/fish/fish.c b/src/vfs/fish/fish.c index 7dfa080e6..ddbc0d47c 100644 --- a/src/vfs/fish/fish.c +++ b/src/vfs/fish/fish.c @@ -1219,18 +1219,16 @@ fish_symlink (const vfs_path_t * vpath1, const vfs_path_t * vpath2) gchar *shell_commands = NULL; char buf[BUF_LARGE]; const char *crpath; - char *rpath, *str_path; + char *rpath; struct vfs_s_super *super; vfs_path_element_t *path_element = vfs_path_get_by_index (vpath2, -1); crpath = vfs_s_get_path (vpath2, &super, 0); if (crpath == NULL) return -1; - rpath = strutils_shell_escape (crpath); - str_path = vfs_path_to_str (vpath1); - qsetto = strutils_shell_escape (str_path); - g_free (str_path); + rpath = strutils_shell_escape (crpath); + qsetto = strutils_shell_escape (vfs_path_get_by_index (vpath1, -1)->path); shell_commands = g_strconcat (SUP->scr_env, "FISH_FILEFROM=%s FISH_FILETO=%s;\n", SUP->scr_ln, (char *) NULL);