[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

[none]



Date: Mon, 12 Jun 2000 04:12:32 -0400 (EDT)

Having misplaced some digests I'm sorta operating in the
dark, but I gather that someone besides me finally has
tripped over a midfile eof.

The digest with the eof did pass through my jury-rigged xpl
offline email reader. The reader prompted something to the
effect of "disk size 109463 | 42225 here: zap midfile eof?"
I responded yes, and the file was made whole without
interrupting a normal xpl run except for my confirmation.
I wouldn't have given it a second thought but for the
follow-up msgs about ascii 26.

When Harry wrote a perfectly good freestanding eof-zapper
in BASIC, I decided the !xyWise overlay needed one that was
integrated, to both eliminate the midfile eof hazard and zap
eof ascii 26s with no extra step after storing a file. It
thus needed to be smaller than Harry's, so I pulled out
my handy C compiler and wrote it.

That was fun. It generates little xpl reports on its
activities that self-destruct after the launching xpl module
reads them. Since it collects size info anyway, !xyWise uses
it too to compensate for xyW3's lack of a size variable.

I open and close files routinely with a !xyWiz pgm (not the
reader) that applies this !xyWise extension. When the pgm
opens a file it compares length on disk against displayed
length. If it detects a discrepancy it goes through a
routine like the one described above (sometimes you don't
want to proceed--e.g., if the file is a binary--thus the
need for confirmation). Storing as usual with eof is a
matter of tapping one key; storing without simply requires
tapping a different key. In either case, after a moment the
file's subdir is listed onscreen. (That and another module
of the same pgm eliminate the need for constant cd \'ing
that was discussed here recently. Virtually the only time
I ever leave my home subdir is when an operation--e.g.,
find--requires that another drive be active.)

!xyWise and !xyWiz are xyWrite 3 xpl, but transplanted to
my xyWin U2 the eof-zapping modules work fine. Unlike the v3
version, however, that U2 isn't and probably never will be
public; xyWin just has too many potholes. Whether or not
ascii 26s concern you, do take a look at the descriptions
of !xyWise/!xyWiz at the URL in my sig. ... Ciao.
					--right-about-a-lot-of-things annie

======================================= adpFisher 
nyc
	xyWrite 3 supplements !xyWise and !xyWiz +
	Wolfgang Bechstein's seafaring adventures:
http://www.escape.com/~yesss/
========================================