/ / Get records. / .globl fget / / fget(buf, nbytes, ioptr); / char *buf; / int nbytes; / FILE *ioptr; / / Returns number of bytes read. Nbytes is the upper / limit. / Use feof to test for end of file. / fget: jsr r0,__csav /Get a stack frame. mov 16(r5),r4 /Get IOV pointer bit $VF_UBF,(r4) /"u" bne 0f /Yes bis $VF_ERR,(r4) /Set error clr r0 / br 1f / 0: mov 12(r5),r0 /Buffer mov 14(r5),r1 /Nbytes call __get / 1: jmp __cret /Done