Microsoft KB Archive/80237

= FIX: Tab Edit Descriptor Fails Crossing Buffer Boundary =

Article ID: 80237

Article Last Modified on 12/1/2003

-

APPLIES TO


 * Microsoft FORTRAN Compiler 5.0
 * Microsoft FORTRAN Compiler 5.1
 * Microsoft FORTRAN Compiler 5.0
 * Microsoft FORTRAN Compiler 5.1

-



This article was previously published under Q80237



SYMPTOMS
When the following conditions are met


 * 1) Output is placed in a record position that is beyond the number of bytes held by the I/O buffer.
 * 2) The FORMAT edit descriptor tabs back to a position that is within the number of bytes held by the I/O buffer.
 * 3) Output is written on top of the existing output that is immediately after the I/O buffer boundary.

the initial data that was output prior to the backwards tab will not be overwritten by the new output. This will only occur with output immediately following the I/O buffer boundary.



RESOLUTION
Since it is difficult to determine if a tab operation is going to cross an I/O buffer boundary, it is best to avoid tabbing back behind and overwriting existing output in a record. If the size of the I/O buffer is increased to a larger number, there will be fewer buffer boundaries and the probability of encountering this problem will be decreased.



STATUS
Microsoft has confirmed this to be a bug in the products listed above. This problem was corrected in FORTRAN PowerStation, version 1.0.



MORE INFORMATION
The following code can be used to reproduce the problem:

Sample code
open(1,file='test.dat',blocksize=1024) write(1,10) '@@@@@@@@@@@@@@',123,456,789 10    format(1024x,a,t1010,3i10) end Output (at end of file test.dat):

123 @@@ 789

Additional query words: 5.10 buglist5.10 fixlist1.00

Keywords: kbfix KB80237

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.