FFILEINFO works for me with the following C code:
#pragma intrinsic FFILEINFO MPE_FFILEINFO
#pragma intrinsic FOPEN MPE_FOPEN
/* Open the Input queue */
f.fv = 0;
f.fs.domain = OLD_PERM_FILE;
a.av = 0;
a.as.exclusive = 1; /* One writer, One reader */
a.as.access = READ_ONLY;
if ( (queue = MPE_FOPEN( "CMTODEV",f.fv,a.av )) == 0 )
abort_run("Unable to open input queue (CMTODEV)");
MPE_FFILEINFO( queue,10,&eof );
if ( ccode() != CCE )
abort_run("Unable to check eof on CMTODEV");
if (eof == 0)
break;
----- Original Message -----
From: "Paul H Christidis" <[log in to unmask]>
To: <[log in to unmask]>
Sent: Tuesday, January 10, 2006 4:35 PM
Subject: [HP3000-L] EOF of message files
> Folks,
>
> Does anyone know the incantations required to programmatically retrieve
> the 'eof' of a message file. I've tried 'fgetinfo' and 'ffileinfo' and, as
> the display below indicates, I keep getting a value of zero for the
> message file and the correct value for the non-message one.
>
> The program is in CM with the following 'fopen' statement:
>
> fnum = fopen (lfile.fname, %3, %10725);
>
> TIA.
>
> Regards
> Paul Christidis
>
>
>
> Listf:
> SIZE TYP EOF LIMIT R/B SECTORS #X MX
>
> SLLIST 80B FA 11474 50000 3 3600 1 *
> SLLIST2 80B VAM 11474 20013 3 4352 17 *
>
>
> My Program:
>
> fnum/name/fopt/eof 14 SLLIST.SUPUTIL.SYS %00005 11474
> fnum/name/fopt/eof 14 SLLIST2.SUPUTIL.SYS %30105 0
>
>
> * To join/leave the list, search archives, change list settings, *
> * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
>
>
>
* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
|