From fa080de7afc95aa1c19a6e6fc0e0708ced2eadc4 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Wed, 8 Jul 2015 20:46:52 -0400 Subject: Initial commit --- noao/digiphot/photcal/mctable/mctmaxrow.x | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 noao/digiphot/photcal/mctable/mctmaxrow.x (limited to 'noao/digiphot/photcal/mctable/mctmaxrow.x') diff --git a/noao/digiphot/photcal/mctable/mctmaxrow.x b/noao/digiphot/photcal/mctable/mctmaxrow.x new file mode 100644 index 00000000..25d21067 --- /dev/null +++ b/noao/digiphot/photcal/mctable/mctmaxrow.x @@ -0,0 +1,19 @@ +include "../lib/mctable.h" + + +# MCT_MAXROW - Return the maximum number of rows of the table. + +int procedure mct_maxrow (table) + +pointer table # table descriptor + +begin + # Check pointer and magic number. + if (table == NULL) + call error (0, "mct_mxrow: Null table pointer") + if (MCT_MAGIC (table) != MAGIC) + call error (0, "mct_mxrow: Bad magic number") + + # Return max number of rows. + return (MCT_MAXROW (table)) +end -- cgit