The LFN Library for Clipper - Change History up to and including Revision 1.11

Revision 1.11

The 1.11 version of the LFN Library was released on July 30, 2009. This version fixes a typo in LF_Directory(), LF_CloseHand() and LF_IsFile() that prevented closing of the FileFind handle. The bug was introduced in Revision 1.10 so users of older versions are not affected.

Revision 1.10

The 1.10 version of the LFN Library was released on October 1, 2007. The reason for this release was the addition of a few new functions for working with dbf files and index files. Some previously unreleased functions for handling substed drives were also added to the library as well as LFN replacements for Clipper's memoread() and memowrit() functions. The new functions are:

LF_DbCreate(), LF_DbUse(), LF_DbCreInd(), LF_DbSetInd(), LF_Subst(), LF_KillSubst(), LF_ChkSubst(), LF_MemoRead() and LF_MemoWrit()

Please note that only single indexes (ntx and ndx) are supported by the LF_DbCreInd() and LF_DbSetInd() functions.

Several years ago I made some global changes in the way that the calls to FT_Int86() were set up and how the result of FT_Int86() calls was checked. Those changes were made mainly for speed reasons and for cosmetic reasons and were not critical in any way, so I saved them for a later release. Well, here it is. The Carryset() function used to check for errors after the FT_Int86() calls was #translated to FT_IsBitOn(), a prg code function, in Nanfor's FTINT86.CH header file. Carryset() has now been replaced with LL_IsBitOn(), which is written in assembly and an order of magnitude faster.

Added a couple of error codes and documented them in the LF_Ferror() docs.

Corrected LF_GetFTime() so the implementation of the <nTimeType> argument complies with the claim in the docs that it is optional.

Improved error checking in LF_GetHInfo().

LF_IsFile() now closes the search handle properly after a failed file find operation.

Removed an unneeded trailing chr(0) in the file names returned by LF_ToLong() and LF_ToShort()

The Low Level Library was updated to version 1.10. The changes are limited to the addition of LL_IsProt(), which checks if the application is running in protected mode or not, and LL_LibVers() which is now written in assembly instead of prg code.

Revision 1.00a

The 1.00a version of the LFN Library was released on March 17, 2003. There are no changes in the LFN Library itself, but the Low Level Library has been updated to version 1.05 for compatibility with version 1.05 of the LanMan Library.

Revision 1.00

The 1.00 version of the LFN Library was released on February 3, 2003. All included files have a time stamp of 01:00:00 on that day. One function was updated for speed reasons and three functions were renamed to reflect a partial reorganizaion of the library. There were also two new functions added to the library for version tracking purposes.

The read/write loop in LF_Fcopy() was moved to assembly. On an "average" collection of files of different sizes this typically results in a speed increase of around 8 to 10 percent in that part of the function. LF_Fcopy() has a lot of overhead for opening the source file, creating the destination file and transferring the file date/time/attributes from the source to the destination, using FT_Int86() for the LFN functions calls. This takes the same amount of time regardless of the file size, which means that the speed of the read/write loop plays a more important role for the total copy time the larger the size of the file is. This is where the speed increase in revision 1.00 can be seen. And vice versa, when copying a group of very small files, the difference from the previous version is hardly noticable at all.

A fourth argument, <l7143Supp>, was added to LF_Fcopy(). This can be used for checking with LF_7143Supp() whether there is support or not for the 7143h DOS function on the destination drive before LF_Fcopy() is called to copy the file. It will save some additional time in the copy process since LF_FCopy() can then skip that test. This can be important if more than one file is copied to the same drive.

I have a thing or two up my sleeve (not LFN related), and when starting to investigate the possibilities of those ideas I realized that they had things in common with the LFN Library in the low level function area. And they will also have things in common with each other. So in order to avoid a complicated future maintenance situation if those projcts ever leave the drawing board, I decided to split the LFN Library in two parts, one with the directly LFN related functions and one with the low level support functions previously labeled "Companion Functions".

The functions affected are LF_I2Attr(), LF_IsBitOn() and LF_Mem2Str(). They are included in a new library file called LL.LIB, and their names have been changed to LL_I2Attr(), LL_IsBitOn() and LL_Mem2Str() respectively. The "LL" part of the names stands for "Low Level". If and when my other ideas materialize, I can reuse those functions without having to duplicate their functionality under new names. That will also save on the EXE file size if LFN functions and functions from the future projects are linked into the same executable.

Of course, the calls to those functions from other parts of the LFN Library have been changed to use the new names, so no changes are needed in your code if you only use the directly LFN related functions from the library. However, if you call any of those three functions directly, you will have to update your code with the new names. And you must of course add LL.LIB to your link script in any case. I am sorry for the inconvenience, but I have from the very start mentioned the possibility of changes that might affect your code :-). However, the "LL" functions are still documented in the same Norton Guide as the "LF" functions.

The new functions LF_LibVers() and LL_LibVers() will return the version number of the LFN Library and the Low Level Library, respectively.


Revision 0.92

The third beta version was released on November 15, 2002. All included files have a time stamp of 01:00:00 on that day. The most important changes are:

A compound function for getting file date/time, size and attributes, based on the already existing LF_GetFTime(), LF_GetFSize() and LF_GetFAttr(), has been added. The new function is called LF_GetFInfo(). It has the same OS support problems as the individual functions have but adds the convenience of getting all the attributes in one function call (provided that the 7143h DOS function is supported at all, of course).

A very similar function, using DOS function 71A6h, Get file info by handle, has also been added. It retrieves the same info as the previous function but does it based on a file handle instead of a file name (although file name support has been added on the Clipper level). This new function is called LF_GetHInfo(), where the "H" stands for "handle". DOS function 71A6h seems to have better support in various Windows versions than function 7143h does.

An entirely new function, LF_Fcopy(), has been added. As the name suggests, it copies an existing file to a new file. This initial version of LF_Fcopy() uses Clipper's fread() and fwrite() to copy the data from the old file to the new one. Although this is not _dreadfully_ slow, it takes a little longer to do its job than Clipper's COPY FILE or __Copyfile. The difference is around 40%, but a 25 MB file is still copied in well under one second on a local drive. Hopefully more speed can be added in the next version.

One additional assembly function has been added:

LF_I2Attr() is intended for converting the numerical file attributes reported by several LFN Library functions to their character equivalents ("A" for Archive, etc).

Several minor changes were made in the docs. They are specified in the history section of each affected source code file.

A group of #defines for handling the returned data from LF_GetFInfo() and LF_GetHInfo() was added to the LFNLIB.CH header file.

The new library functions were added to the demo.

Revision 0.91

The second beta version was released on August 27, 2002. All included files have a time stamp of 01:00:00 on that day. The most important changes are:

The internal functions (previously in FIND1ST.PRG) for retrieving file date, time and attributes have been moved to a separate file called DTAFUNCP.PRG. They have also been renamed following a "_lf()" pattern.

All bit manipulation not directly supported by functions in CLIPPER.LIB (specifically the routines for retrieving date and time after having found a file with the findfirst/findnext DOS services) has been moved to assembly. Those routines are now in DTAFUNCA.ASM.

Two additional assembly functions have been added:

LF_Mem2Str() is primarily used in the SFN version of the file find functions for copying the DTA to a string for further processing. But it can be used for copying any data from any memory location (within certain limits).

LF_IsBitOn() can be used for testing if a bit is set or not in any 16-bit numeric integer. The intended use in connection with the LFN Library is for checking the file attributes returned by the file find functions.

Support has been added for the extended get/set attributes services with the new library functions LF_GetFTime(), LF_SetFTime(), LF_GetFAttr(), LF_SetFAttr() and LF_GetFSize(). Whether the OS supports those functions of not can be checked with another new function, LF_7143Supp().

Several minor changes were made in the docs. They are specified in the history section of each affected source code file.

Several groups of #defines were added to the LFNLIB.CH header file.

The documentation regarding date and time handling in the underlying DOS services was updated with additional details.

The new library functions were added to the demo.

The file date display in the demo was changed to dtos() format in order to include the century without requiring reallocation of the already limited screen space.

The version number has been removed from the title of the Norton Guide and moved inside the information section of the file. If you have used WEG to read the previous version of the guide, the number of that version is stored in WEG's guide list. To update it, you have to open the Guide Manager under the File menu and remove the LFN Library line before adding it back by selecting the new version of the NG. This operation will not be necessary with future updates.

Revision 0.90

The initial beta version of the LFN Library was released on July 31, 2002. All included files had a time stamp of 01:00:00 on that day.

Go back to the LFN Library main page

This document was last revised on 2009-07-20