1999-09-18 10:51:31 +00:00
|
|
|
#include <stdio.h>
|
|
|
|
#include "f2c.h"
|
|
|
|
|
|
|
|
#undef abs
|
|
|
|
#undef min
|
|
|
|
#undef max
|
|
|
|
#include <stdlib.h>
|
2003-07-11 03:42:19 +00:00
|
|
|
void f_exit (void);
|
1999-09-18 10:51:31 +00:00
|
|
|
|
2003-07-11 03:42:19 +00:00
|
|
|
int
|
|
|
|
s_stop (char *s, ftnlen n)
|
1999-09-18 10:51:31 +00:00
|
|
|
{
|
2003-07-11 03:42:19 +00:00
|
|
|
int i;
|
1999-09-18 10:51:31 +00:00
|
|
|
|
2003-07-11 03:42:19 +00:00
|
|
|
if (n > 0)
|
|
|
|
{
|
|
|
|
fprintf (stderr, "STOP ");
|
|
|
|
for (i = 0; i < n; ++i)
|
|
|
|
putc (*s++, stderr);
|
|
|
|
fprintf (stderr, " statement executed\n");
|
|
|
|
}
|
1999-09-18 10:51:31 +00:00
|
|
|
#ifdef NO_ONEXIT
|
2003-07-11 03:42:19 +00:00
|
|
|
f_exit ();
|
1999-09-18 10:51:31 +00:00
|
|
|
#endif
|
2003-07-11 03:42:19 +00:00
|
|
|
exit (0);
|
1999-09-19 05:59:11 +00:00
|
|
|
|
|
|
|
/* We cannot avoid (useless) compiler diagnostics here: */
|
|
|
|
/* some compilers complain if there is no return statement, */
|
|
|
|
/* and others complain that this one cannot be reached. */
|
|
|
|
|
2003-07-11 03:42:19 +00:00
|
|
|
return 0; /* NOT REACHED */
|
1999-09-18 10:51:31 +00:00
|
|
|
}
|