I have noticed that `zipinfo' now shows "defN" instead of "stor" as
the compression method for empty files. Various tests with older and
new versions of 7-Zip, FreeBSD's `zip' and an ancient version of
WinZip showed that all these tools use "stor" as the compression
method for empty files.

I haven't found any technical documentation or recommendation about
this, and I don't think it's an error to use "defN" for empty (zero
length) files. However, it may be more convenient for the unzipping
algorithm and for overall compatibility(*) if empty files were added
to zip archives using "stor" as the compression method (set iMethod=0,
as for directories)?

(*) For example, my ancient version of WinZip (15.5), after all
calling itself "world's #1 compression software" with
"industry-leading compression"(**), just ignores empty files with
"drwxr-xr-x" instead of "-rw-r--r--", so other unzipping utilities may
also deliberately choose to ignore something that claims to be
compressed by "defN" but has 0 bytes of data?

(**) I really loved this program, it worked great for me before I
decided to switch to open source tools, and I didn't intend to speak
ill of it.

--Florian
_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to