From fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Wed, 8 Jul 2015 20:46:52 -0400 Subject: Initial commit --- sys/fmtio/fmtinit.x | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 sys/fmtio/fmtinit.x (limited to 'sys/fmtio/fmtinit.x') diff --git a/sys/fmtio/fmtinit.x b/sys/fmtio/fmtinit.x new file mode 100644 index 00000000..0d8ea547 --- /dev/null +++ b/sys/fmtio/fmtinit.x @@ -0,0 +1,23 @@ +# Copyright(c) 1986 Association of Universities for Research in Astronomy Inc. + +include + +# FMT_INIT -- The following is called by SPRINTF and CLPRINTF to set a flag to +# close the mem file or finish the CL command, respectively, when +# the end of the format string is reached. This entry is also called +# by the iraf main at startup time to initialize the printf common. + +procedure fmt_init (ftype) + +int ftype +include "fmt.com" + +begin + if (ftype == FMT_INITIALIZE) { + ip = 1 + format[ip] = EOS + ofile_type = REGULAR_FILE # fpradv + fmt_state = FMT_START # fprfmt + } else + ofile_type = ftype +end -- cgit