Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
path: root/src/sys
diff options
context:
space:
mode:
Diffstat (limited to 'src/sys')
-rw-r--r--src/sys/consoleinterface.cc8
-rw-r--r--src/sys/consoleinterface.h6
-rw-r--r--src/sys/sys.h37
3 files changed, 28 insertions, 23 deletions
diff --git a/src/sys/consoleinterface.cc b/src/sys/consoleinterface.cc
index 45df367..5740807 100644
--- a/src/sys/consoleinterface.cc
+++ b/src/sys/consoleinterface.cc
@@ -10,11 +10,13 @@
#include <stdlib.h>
-namespace sys {
+namespace sys
+{
ConsoleInterface *ConsoleInterface::consoleinterface_instance = 0;
-ConsoleInterface::ConsoleInterface() {
+ConsoleInterface::ConsoleInterface()
+{
if (consoleinterface_instance) {
std::cerr << "multiple singleton instances: sys::ConsoleInterface" << std::endl;
sys::quit(2);
@@ -27,7 +29,7 @@ ConsoleInterface::~ConsoleInterface()
consoleinterface_instance = 0;
}
-ConsoleInterface *ConsoleInterface::instance()
+ConsoleInterface *ConsoleInterface::instance()
{
return consoleinterface_instance;
}
diff --git a/src/sys/consoleinterface.h b/src/sys/consoleinterface.h
index 6540d95..0215d55 100644
--- a/src/sys/consoleinterface.h
+++ b/src/sys/consoleinterface.h
@@ -27,10 +27,12 @@
#define con_debug if (0) *(std::ostream*)(0)
#endif
-namespace sys {
+namespace sys
+{
/// interface for the client and server Console classes
-class ConsoleInterface {
+class ConsoleInterface
+{
public:
/// default constructor
ConsoleInterface();
diff --git a/src/sys/sys.h b/src/sys/sys.h
index dec5ab9..4769832 100644
--- a/src/sys/sys.h
+++ b/src/sys/sys.h
@@ -13,25 +13,26 @@
#define MAXCMDSIZE 1024
/// contains operating system dependent functions
-/** sys is a core subsystem
+/** sys is a core subsystem
*/
-namespace sys {
- typedef void (* signalfunc)(int signum);
-
- /// create a directory
- extern bool mkdir(const char *path);
- /// intercept OS signals
- extern void signal(int signum, signalfunc handler);
- /// quit
- /** @param status return value
- */
- extern void quit(int status);
-
- /// suspend process for a number of seconds
- extern void sleep(float seconds);
-
- /// return the current system time of day, in seconds after midnight
- extern unsigned long time();
+namespace sys
+{
+typedef void (* signalfunc)(int signum);
+
+/// create a directory
+extern bool mkdir(const char *path);
+/// intercept OS signals
+extern void signal(int signum, signalfunc handler);
+/// quit
+/** @param status return value
+ */
+extern void quit(int status);
+
+/// suspend process for a number of seconds
+extern void sleep(float seconds);
+
+/// return the current system time of day, in seconds after midnight
+extern unsigned long time();
}