Readme for the LZX plugin for Total Commander
The current version of the LZX plugin is 2.2 !
This documentation explains how to install/update/uninstall the LZX plugin. It contains also the
feature list, the contact information and the version history. It was last modified on 13.07.2012.
For a German version see Liesmich
für das LZX-Plugin für Total Commander.
This documentation is part of the archive
lzx_plugin.zip
available on the plugins page
of the website of Total Commander.
Features of the LZX plugin
The LZX plugin "Unlzx.wcx" makes it possible to unpack LZX archives
with Total Commander. LZX is a popular AMIGA pack format. More LZX stuff and information can be
found at The LZX Page by Jonathan Forbes and Tomi Poutanen.
This webpage is from the authors of the LZX compression algorithm and the original LZX programs.
The plugin has following features:
- Support for viewing the LZX archive content.
Open archive file with extension .lzx
with Enter or Return, Ctrl+PgDn or with a double mouse click.
- Extract selected files from an LZX archive or
unpack all files with path with Alt+F9.
- Test the integrity of LZX archives with Alt+Shift+F9.
See question 1 in the LZX FAQ at The LZX Page
for a possible reason for a damaged archive.
- Support for a text search in files in LZX archives
with Alt+F7 and options "Search archives" and "Find text" enabled.
See at chapter Update how to enable this feature when updating
the LZX plugin from prior v2.0.
- File attribute handling can be customized.
See chapter
Settings for file attribute handling
in the documentation for the INI settings.
- File date handling can be customized and workarounds for the Y2K
bug of LZX.
See chapter Settings
LZXPacker and TouchFiles in the documentation for the INI settings.
- Special feature 1: Set automatically
the archive file time to the newest file time inside the archive.
See chapter Setting ArchiveTime
in the documentation for the INI settings.
- Special feature 2: Save file
notes (comments) to descript.ion while unpacking files.
See chapter Setting SaveFileNotes
in the documentation for the INI settings.
Please read the documentation INI settings of the LZX plugin
for detailed information about the INI file support by this unpacker plugin and the special features.
Known limitations: Paths with Unicode characters are not supported by the plugin!
Contact information
V2.2 of the LZX plugin was developed by Ing. Ofner Michael.
If you have suggestions for further improvements, or if you have found a program error
or a mistake in the HTML documentations, post a reply on Total Commander plugins forum topic
Updated version of the LZX packer plugin available.
The LZX plugin was first written by Sebastian Erbert.
For developers and programmers: The source code of the LZX plugin is also available in the
archive lzx_source.zip.
Instructions for a new installation
If a previous version of the LZX plugin is installed already, please
continue reading at chapter Updating the LZX plugin.
Since v6.50 Total Commander supports a guided automatic installation of plugins. Just
double click on "lzx_plugin.zip" stored on
a local drive or open it with key Enter or Return
and follow the instructions, if the plugin is not installed already with this method.
A little disk space can be saved by deleting the German HTML documentations
of the LZX plugin in the installation directory of the plugin. Also the English
documentations can be deleted, if an extracted version is not needed.
If the automatic installation feature is disabled with AutoInstallPlugins=0
in Wincmd.ini or if a version of Total Commander prior v6.50 is used, do
following to install and configure the plugin manually:
- Unzip at least the file "Unlzx.wcx"
to the preferred directory.
- Choose from menu "Configuration"
the menu item "Options".
- Select the branch/tab "Packer".
- Click on the button "Configure packer extension WCXs" or
"Configure packer extension DLLs" depending on your version.
- Type "lzx" as new extension
in the small field in the upper right corner.
- Click on button "New type",
browse to Unlzx.wcx and open it.
- Click twice the button "OK"
to finish the configuration of the plugin.
The described steps should add following into the INI of Total Commander:
[PackerPlugins]
lzx=128,path to unlzx.wcx\Unlzx.wcx
The number after the equal sign is the info for Total Commander, that this
packer plugin supports the text search in archived files (PK_CAPS_SEARCHTEXT).
Updating the LZX plugin
If a previous version of the LZX plugin is installed already, install the new version
either with the automatic installer to the same directory as the already existing plugin or
manually by unpacking new "Unlzx.wcx" with overwriting existing
Unlzx.wcx. If write access is denied to the file because the plugin is already loaded, close
Total Commander and restart TC to unload the plugin and get write access to the file.
If the text search capability of the LZX plugin should be available, the LZX plugin
packer options must be reconfigured now manually by executing following steps:
- Choose from menu "Configuration"
the menu item "Options".
- Select the branch/tab "Packer".
- Click on the button "Configure packer extension WCXs" or
"Configure packer extension DLLs" depending on your version.
- Select the extension "lzx"
in the small field in the upper right corner.
- Set the cursor at start of the large field "Associate with" and
replace the number 0 with the number 128.
If there is no number (after an automatic install), do nothing here. Total Commander will get
the packer options from the plugin on first usage.
- Click twice the button "OK"
to finish the reconfiguration of the plugin.
At least v5.51 of Total Commander is needed for usage of the text search feature.
Additionally delete the file "lzx_read.txt" in
the plugin directory which exists maybe from a previous version of the plugin
and unzip the new HTML documentations to the plugin directory (optional).
Uninstalling the LZX plugin
If the LZX plugin is not needed anymore and should be uninstalled, execute following steps:
- Choose from menu "Configuration"
the menu item "Options".
- Select the branch/tab "Packer".
- Click on the button "Configure packer extension WCXs" or
"Configure packer extension DLLs" depending on your version.
- Select the extension "lzx"
in the small field in the upper right corner.
- Set the cursor into the large field "Associate with",
remember the path to Unlzx.wcx and delete the complete text in this field.
- Click twice the button "OK" to finish
the deletion of the LZX plugin from the INI of Total Commander.
- Browse to the LZX plugin directory and delete all files starting with
"unlzx" and also the directory itself, if it is
empty now. If the plugin Unlzx.wcx cannot be deleted, close Total Commander
and restart it to unload the plugin and so get write/delete access to the file.
- Finally search for "pkplugin.ini" in the directory of Wincmd.ini
and if this INI exists, open it with a text editor, search for the section [Unlzx]
and delete the whole section, or the whole INI file, if it does not contain settings from other
packer plugins. If pkplugin.ini was not used, search for "Unlzx.ini"
in the directory of Wincmd.ini or the plugin directory and delete this file too.
Thanks for testing/using the LZX plugin!
Version history of the LZX plugin
V2.2 from 13.07.2012
64-bit version now available with same functioning as 32-bit version.
The used functions from the Windows libraries are embedded in x64 version of the plugin
to avoid a dependence on msvcr100.dll. But that makes the x64 version considerable larger as
the x86 version of the plugin which is linked dynamically with kernel32.dll and msvcrt.dll.
Bug fix:
- Small bug on reading and comparing the INI settings fixed. This error in code has had
no effect on functioning of the plugin nor any other application or file.
V2.1 from 28.12.2011
Bug fixes:
- Updating an existing comment for a file in descript.ion with hidden attribute set was not
working on Windows 2000 and later versions of Windows because overwrite access mode denied.
Creating descript.ion and appending a new file comment worked as also updating on Windows 9x.
Also this problem did not exist for descript.ion with hidden attribute not set. A different
method is used now to overwrite a hidden descript.ion to update an already existing file
comment in descript.ion not equal the stored file comment in the archive.
- V2.0 of the plugin tried sometimes to free memory not allocated before because of a
missing initialization. And already allocated memory was not released before exiting on
error during opening an archive.
- On determining the path for the file name of the INI file of the plugin, it is possible
theoretically under Windows 2000 / XP that a buffer overflow occurs if the complete file name
of Unlzx.wzx with path is longer than 259 characters (error in function GetModuleFileName
of Microsoft). This improbable case is detected now and with this fix a possible security gap
is closed caused by a buffer overflow.
Small enhancements:
- A file name without spaces is saved without double quotes in descript.ion on saving a file
note. Only file names with a space are stored enclosed in double quotes in descript.ion. If
a user modifies manually the text file descript.ion with a text editor and encloses in double
quotes a file name without a space, the plugin v2.0 has not found this file name without a space
in descript.ion. As a result it could happen that after extraction two comments exist for a file
in descript.ion because the file name is saved once with and once without double quotes. Total
Commander evaluates in this case always the comment from the line with the file name without the
double quotes. V2.1 of the plugin detects now also a file name without a space manually enclosed
in double quotes in descript.ion and updates its comment on difference to the file note stored
in the LZX archive. But the manually added double quotes are removed on update of the file
comment by the plugin.
- Last access time of the archive file is not set any more to time of newest file inside
the archive if using setting ArchiveTime
with value greater 0. The last access time is now always the current system time because
of reading the data from the archive file. There is one exception. Last access time of archive
file is set also to time of newest file inside the archive as creation and last modification
time if the file time is in future in comparison to current system time.
V2.0 from 03.01.2007
Bug fixes:
- Fixed wrong month value in date of archived files (0-11 instead of 1-12).
- Fixed problem with file year 1978/1979 by setting it to 1980 because
a year < 1980 is not possible in Windows FAT environment.
- Fixed wrong file extraction if the archived AMIGA file name (with path) contains a backslash.
For AMIGA/UNIX file systems the slash is the separator for directory names and a backslash is
a normal allowed character in directory/file names. Backslashes in directory/file names in
an AMIGA or UNIX packed LZX archives are now converted to an underscore. This is a special
AMIGA/UNIX to MS-DOS/Windows conversion problem.
- Fixed also unpacking files with a size of 0 bytes (empty files) which are displayed,
but not extracted by the previous versions.
This plugin is currently
the only unlzx routine for every OS (operating system) which handles stored empty files and
directories in an LZX archive correct while extracting it.
- Trailing spaces on directory names are now also automatically trimmed like Total Commander
does it too. So the directories are shown in an opened archive as created by Total Commander
while unpacking the archive.
- Internal buffers for full file names increased from 256 to Windows ANSI standard of 260 bytes
and this limit is also tested before copying file names to avoid a buffer overflow.
New features:
- Support for an INI file added for various custom settings.
- Workarounds and fixes added for all problems with wrong year/month of a file caused by the Y2K
bug of the original LZX and the 3 different storage formats for file dates greater than 31.12.1999
(original + 2 available patches) according to the user specification LZXPacker= in the
INI file. See LZX date problem handling with the LZX plugin
for details about all date problems and fixes.
- The files of an LZX archive are extracted now by default with correct file
time if the setting TouchFiles= in the INI has the default value 0.
- The plugin restores now also the file attributes as much as possible. It can be specified in the
INI how to handle the file attributes while extracting the files and viewing the archive content.
- Test archive integrity feature (Alt+Shift+F9) added (= extract without writing to a file).
- The plugin supports now also a text search in archived files. Function GetPackerCaps()
was added to enable this feature and a workaround for a bug of Total Commander < v7.00
at this feature. (Developers please see Unlzx.cpp in the source package for details.)
- The file comments (AMIGA filenotes) can be also written now to descript.ion while unpacking
if the file is not unpacked by Total Commander for temporary usage.
This
is the first packer plugin for Total Commander which supports file comments!
- It is possible to set automatically the file time of the archive file to the newest file
time in the archive.
This is maybe the first packer/unpacker program which
has such a feature for already existing archives without the need of ugly workarounds.
Further improvements:
- Files with a write error while extracting (floppy disk full?) are now automatically deleted and
the error is also reported back to Total Commander which then informs the user with a message.
- The version information of the plugin is now bilingual (English and German). The version information
is shown on the tab "Version" in the properties of the file Unlzx.wcx. To view the properties
click with secondary (right) mouse button on Unlzx.wcx and choose "Properties" or press
Alt+Return when the file has the focus. The comments of the INI settings are also bilingual according
to the current user country setting in the "Regional and Language Settings" of Windows.
- Internal structures reorganized to decrease memory usage and plugin compiled with the
VS6 linker option /FILEALIGN:512 to decrease size of the plugin by approximately 33%.
- Extensive and hopefully helpful HTML documentations in English and German are packed
also to the zip-file of the plugin.
All these fixes and improvements were added by Ing. Ofner Michael.
All previous versions were written and released by Sebastian Erbert.
Thanks to Sebastian Erbert and Christian Ghisler for additional support and information!
V1.1 from 01.09.2004
Last version released by Sebastian Erbert, first author of the LZX plugin.
Fixed error caused by not initializing the output buffer to 0.
(Changed version number to 1.1 since first release was named 1.0.)
V0.4 from 28.08.2004
Workaround for files with bad CRC which are not extracted furthermore as before, but are
reported to Total Commander now. So the user is informed now, which files were not unpacked
because of a CRC error. Main reason for bad archives - see question 1 in the LZX FAQ at
The LZX Page by Jonathan Forbes and Tomi Poutanen.
V0.3 from 03.03.2002
Bug fix: some archives were not unpacked correctly.
V0.2 from 12.01.2002
Bug fix: subdirectories in the archives were not created.
Progress monitor implemented (code from Christian Ghisler used).
V0.1 from 17.12.2001
First test version.