From 4fc41065a31cc8bd477ff5bf2d89f9f595002227 Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Fri, 29 Feb 2008 13:04:08 +0100 Subject: [PATCH] pvfs_resolve: fix endless loop with trailing ".." We also need to move the NULL termination. metze --- source/ntvfs/posix/pvfs_resolve.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/ntvfs/posix/pvfs_resolve.c b/source/ntvfs/posix/pvfs_resolve.c index 2bfc47bef..c12903857 100644 --- a/source/ntvfs/posix/pvfs_resolve.c +++ b/source/ntvfs/posix/pvfs_resolve.c @@ -399,7 +399,7 @@ static NTSTATUS pvfs_reduce_name(TALLOC_CTX *mem_ctx, if (ISDOTDOT(components[i])) { if (i < 1) return NT_STATUS_OBJECT_PATH_SYNTAX_BAD; memmove(&components[i-1], &components[i+1], - sizeof(char *)*(num_components-(i+1))); + sizeof(char *)*(num_components-i)); i -= 2; continue; } -- 2.34.1