[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
re: new system calls
Hi there!
Yesterday I promised to repost my code of a halt and reboot program, but
I could not find the source any more, so I have to rewrite it from scratch.
That is no big deal:
----------------cut here---------------------
#include <mintbind.h>
#ifdef __GNUC__
#define Shutdown(a) (void)(trap_1_ww((short)0x151, ((short)(a))))
#else
YOU LOSE
#endif
/* uncomment the apropiate thing */
#define HALT
/* #define REBOOT */
int
main()
{
#ifdef HALT
int val = 0;
#else
int val = 1;
#endif
Shutdown(val);
return 0;
}
-------------cut again---------------
Ciao,
Ulrich
--
+---------------+----------------------------+-----------------------+
| Ulrich Kuehn | Internet: | Life is uncertain -- |
| Cand.Math.Inf | kuehn@math.uni-muenster.de | eat the dessert first |
+---------------+----------------------------+-----------------------+