diff options
author | Joseph Hunkeler <jhunkeler@gmail.com> | 2015-07-08 20:46:52 -0400 |
---|---|---|
committer | Joseph Hunkeler <jhunkeler@gmail.com> | 2015-07-08 20:46:52 -0400 |
commit | fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4 (patch) | |
tree | bdda434976bc09c864f2e4fa6f16ba1952b1e555 /sys/mtio/mtfile.x | |
download | iraf-linux-fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4.tar.gz |
Initial commit
Diffstat (limited to 'sys/mtio/mtfile.x')
-rw-r--r-- | sys/mtio/mtfile.x | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/sys/mtio/mtfile.x b/sys/mtio/mtfile.x new file mode 100644 index 00000000..c07a550b --- /dev/null +++ b/sys/mtio/mtfile.x @@ -0,0 +1,24 @@ +# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc. + +define SZ_NODENAME 9 + +# MTFILE -- Test a filename to see if it is the name of a magtape file. +# A magtape file is characterized by the filename prefix "mt" (ingnoring +# the nodename prefix if any). + +int procedure mtfile (fname) + +char fname[ARB] #I filename to be tested + +int ip, junk +char nodename[SZ_NODENAME] +int ki_extnode() + +begin + ip = ki_extnode (fname, nodename, SZ_NODENAME, junk) + 1 + + if (fname[ip] == 'm' && fname[ip+1] == 't') + return (YES) + else + return (NO) +end |