id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc	blockedby	blocking	branch_state	votes
2151	Odd behavior when opening ZIP file that contains the same file twice	zaytsev	slavazanko	"Forwarded from Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=347738

{{{
From: Marco Herrn <marco@mherrn.de>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: when opening zip file that contains the same file twice, mc behaves oddly
Date: Thu, 12 Jan 2006 13:09:43 +0100

When a zip file contains a file with the same path and name more than
once, mc doesn't display all the information.

For example the bribblebox from bribble.com (available from
http://prdownloads.sourceforge.net/bribble/bribble-1.5.35.tar.bz2?download)
contains a Java Archive File (jar) which is in fact a zipfile with a
specific structure (The jarfile is
bribble-1.5.35/server/bribble-1_5_35.jar). This archive contains the
file META-INF/MANIFEST.MF twice. (Of course this is wrong and the
jar-file can be considered broken).

These two MANIFEST.MF files have different content, so they can be
distinguished. When opening this file in mc, there are two META-INF
directories, each of which contains two MANIFEST.MF files. When
viewing these MANIFEST.MF files (via F3), all four show the content of
the same one.

It would be of course better, if mc would display only one META-INF
directory with two MANIFEST.MF files. And viewing them should of
course display the correct contents, not the same content for both.

I hope I made the problem clear. It can be easily reproduced by
downloading the above mentioned tar.bz2, unpacking it and viewing the
jar-file in mc. To view the actual contents, the unzip tool can be
used, for example 'unzip -l bribble-1.5.35/server/bribble-1_5_35.jar'


Regards
Marco
}}}

I would have fixed this bug, but I don't know Perl :-( I think that duplicate directories should be trivial to filter, but I am not sure of what to do with duplicate files.

If you give them the same name, then the VFS will not able to tell which one to show. If you give them different name it's not obvious that these files are duplicate. 

Maybe give them different names like with a special character that can not occur in the filenames? Then it's quite obvious that there's something wrong with the archive.

Thanks!"	defect	accepted	minor	Future Releases	mc-vfs	master			onlyjob@…			no branch	
