aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--sshfs.c2
2 files changed, 5 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index b7362bd..8c203b1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2006-03-08 Miklos Szeredi <miklos@szeredi.hu>
+
+ * Fix bug in symlink transformation. Reported by Ralf Hoffmann
+
2006-02-24 Miklos Szeredi <miklos@szeredi.hu>
* Add workaround for broken truncate on old sftp servers. Can be
diff --git a/sshfs.c b/sshfs.c
index 64f037d..636b856 100644
--- a/sshfs.c
+++ b/sshfs.c
@@ -1339,7 +1339,7 @@ static void transform_symlink(const char *path, char **linkp)
return;
dotdots--;
- newlink = malloc(dotdots * 3 + l ? strlen(l) : 1 + 10);
+ newlink = malloc(dotdots * 3 + strlen(l) + 2);
if (!newlink) {
fprintf(stderr, "sshfs: memory allocation failed\n");
exit(1);