Mail Archives: djgpp/2000/11/08/12:23:37
Eli Zaretskii (eliz AT is DOT elta DOT co DOT il) writes:
> On 7 Nov 2000, James Owens wrote:
>> (uO.volflag == 1 && !isfloppy(nLabelDrive))) /* -$: no fixed */
>>
>> If I comment out the second line it works, so either the -$ parameter is
>> not setting u0.volflag, or isfloppy() is returning the wrong result. (I
>> guess).
> The easiest way to know for sure is either to run the program under a
> debugger, put a breakpoint on this line, and print the value of both
> uO.volflag and isfloppy(nLabelDrive); or use printf to show those
> values.
I'm of the printf school of debugging, but I can't remember the command to
convert an integer to a string so I've been using IF . . . PRINTF. . .
The problem is definitely not uO.volflag; this is 1 when the $ parameter
is present, and 0 when it isn't.
If I replace the line with
(uO.volflag == 1 && nLabelDrive > 2)) /* -$, but not A: or B: */
then the program labels the drive if I run from A:\ prompt, and does not
label if I run from C:\ prompt. So I'm still inclined to suspect
isfloppy(). Thanks for explaining it more fully; I'll study it some more.
But it gets worse. When I run UNZIPSFX with this change and only this
change, the unzip process fails after a few filenames, complaining of a
bad offset. This tempts me to give up.
--
James Owens ad354 AT Freenet DOT carleton DOT ca
Ottawa, Ontario, Canada
- Raw text -