#81 No $ZEOF on empty Files in V5.4

closed-invalid
nobody
None
5
2010-02-15
2010-02-14
Jens Wulf
No

Look at the following:
root@linux2:/tmp# ls -l
total 0
-rw-r--r-- 1 root root 0 2010-02-14 20:25 test
root@linux2:/tmp# m

GTM>S DEV="/tmp/test" O DEV:READONLY U DEV S X=$ZEOF C DEV W X
0
GTM>

This happens in the new Version 5.4
Greets Jens

Discussion

  • K.S. Bhaskar
    K.S. Bhaskar
    2010-02-15

    This is the result of a bug fix in V5.3-004:

    GT.M now handles $ZEOF for disk files correctly by setting it to 1 only after a read to the end of file. Previously $ZEOF would inappropriately be set to 1 when opening a zero length file READONLY or when opening a file for APPEND - in both cases prior to any read operation. Note: $ETRAP and $ZTRAP occur on the READ after $ZEOF is set by a prior READ, while EXCEPTION is triggered on the same read that sets $ZEOF. [UNIX] (C9I04-002984)

     
  • K.S. Bhaskar
    K.S. Bhaskar
    2010-02-15

    • status: open --> closed-invalid