Dec 122017
 
Disk Utility V1.2 Plugs holes on HD.
File PLUG12.ZIP from The Programmer’s Corner in
Category HD Utilities
Disk Utility V1.2 Plugs holes on HD.
File Name File Size Zip Size Zip Type
ABSDIO.ASM 2490 1038 deflated
BPB.H 842 336 deflated
DGLOBAL.H 807 291 deflated
DIR.H 1209 511 deflated
DIRUTIL.C 7454 1683 deflated
FATUTIL.C 5714 1153 deflated
FMOVER.C 3940 1237 deflated
GDATA.C 1567 433 deflated
LOADBPB.C 3191 907 deflated
PLUG.C 3279 899 deflated
PLUG.DOC 2875 1385 deflated
PLUG.EXE 13584 7826 deflated
PLUG12.NEW 1058 565 deflated
PRTBPB.C 1266 494 deflated
PRTBPB.EXE 10752 6109 deflated
QSORT.C 1299 575 deflated
TPCREAD.ME 199 165 deflated

Download File PLUG12.ZIP Here

Contents of the PLUG.DOC file




DISK FREE-SPACE DEFRAGMENTER - PLUG.EXE
WITH SOURCE CODE


This document describes the function of the disk free-space
defragmentation program PLUG.EXE written by Larry Himes,
July, 1987. The program was written primarily as an exercise
in handling low-level MS-DOS disk internal structures and is
provided in source and executable form free of charge by the
author. This software carries no warranties, express or im-
plied: USE AT YOUR OUN RISK.

Purpose: PLUG de-fragments free space on hard or floppy disks
by finding files which best fit "holes" of free space in the
disk structure and moving the files into the "holes". Holes
are filled only by files which start at physically higher
locations on the media, thus resulting in most of the used
disk space being packed into the "lower", or outer end of the
disk.

Implementaion notes:

. Implementation was done using the Large Memory model (-mls
option of Lattice C version 3.2. The single Assembly
Language routine, _ABSDIO.ASM, was assembled using Micro-
soft MASM version 4.0.

. The Lattice functions getmem() and rlsmem() were used for
dynamic memory management because they are marginally more
efficient than malloc() and free(). Malloc() and free()
may be substituted for re-compilation with compilers which
do not support these functions, provided certain cautions
are exercized (see next item).

. Special care should be taken with the PUTINFO() function if
it is ported to other compiler implementations. Specifically,
the function relies on the fact that the Lattice function
getmem() returns pointers whose offset portions are always
zero in the large data model. If this peculiarity is not
taken into account and adjusted for during a port, DISASTER
COULD RESULT.

. A version of qsort() written by me is included in the
package. It is somewhat more efficient than that supplied
by Lattice and should be quite portable, but any standard
version of qsort() may be used.

Files in archive:


BPB.HHeader file defining the structure of a BIOS
Parameter Block in the boot record of a disk.

DGLOBAL.HGlobal Data element external definitions.

DIR.HHeader file defining directory structures.

DIRUTIL.CFunctions dealing with directory processing.

FATUTIL.CFunctions dealing with FAT processing.

FMOVER.CControls moving of files in PLUG.EXE.

GDATA.C Global data element definitions.

LOADBPB.CFunctions to load and print BPB data.

PLUG.CPLUG Main() function.

PRTBPB.CMain program to print BPB and check FATs.

QSORT.C My own version of QSORT.

ABSDIO.ASMAssembly routine for absolute (logical sector-oriented)
disk i/o.

PRTBPB.EXEPRTBPB executable.

PLUG.EXEPLUG executable.

PLUG.DOCThis File.




 December 12, 2017  Add comments

Leave a Reply