From 58909eb7081556d657eb2673429fbb653bd66b6c Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Fri, 2 Apr 2010 14:56:08 +0400 Subject: [PATCH] Ticlet #1909: fix of extfs_read_archive() function. Fixed bug introduced in ad9c1daad88d4972f81fd73ab06fb8b90027cb7a commit: incorrect handling of "." and ".." directories within atchives. Signed-off-by: Andrew Borodin --- lib/vfs/mc-vfs/extfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/vfs/mc-vfs/extfs.c b/lib/vfs/mc-vfs/extfs.c index c567bc604..ea8c9bc15 100644 --- a/lib/vfs/mc-vfs/extfs.c +++ b/lib/vfs/mc-vfs/extfs.c @@ -486,7 +486,7 @@ extfs_read_archive (int fstype, const char *name, struct archive **pparc) *(p++) = '\0'; q = cfn; } - if (S_ISDIR (hstat.st_mode) && (strcmp (p, ".") || !strcmp (p, "..") == 0)) + if (S_ISDIR (hstat.st_mode) && (strcmp (p, ".") == 0 || strcmp (p, "..") == 0)) goto read_extfs_continue; pent = extfs_find_entry (current_archive->root_entry, q, TRUE, FALSE); if (pent == NULL)