diff --git a/client/cookie.html b/client/cookie.html
deleted file mode 100644
index 65cddd0..0000000
--- a/client/cookie.html
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
-
-
-
-
-
-cookie set
-
-
diff --git a/server/app.js b/server/app.js
index f2deba2..4bad472 100755
--- a/server/app.js
+++ b/server/app.js
@@ -7,51 +7,6 @@ var sys = require('sys'),
o_.merge(global, require('./settings'));
try { o_.merge(global, require('./settings.local')); } catch(e) {}
-try {
- var daemon = require('./libs/daemon/daemon'),
- start = function() {
- daemon.init({
- lock: PID_FILE,
- stdin: '/dev/null',
- stdout: LOG_FILE,
- stderr: LOG_FILE,
- umask: 0,
- chroot: null,
- chdir: '.'
- });
- },
- stop = function() {
- process.kill(parseInt(require('fs').readFileSync(PID_FILE)));
- };
-
- switch(process.argv[2]) {
- case 'stop':
- stop();
- process.exit(0);
- break;
-
- case 'start':
- if(process.argv[3])
- process.env.EXPRESS_ENV = process.argv[3];
- start();
- break;
-
- case 'restart':
- stop();
- start();
- process.exit(0);
- break;
-
- case 'help':
- sys.puts('Usage: node app.js [start|stop|restart]');
- process.exit(0);
- break;
- }
-} catch(e) {
- sys.puts('Daemon library not found! Please compile ' +
- './libs/daemon/daemon.node if you would like to use it.');
-}
-
var app = express();
//app.set('env', 'development');
app.use(require('method-override')());
@@ -125,3 +80,5 @@ app.use('/app/signoff', function(req, res) {
res.signOff();
res.send(new packages.Success('goodbye'));
});
+
+console.log('Ajax IM server started...');
diff --git a/server/dev/app.js b/server/dev/app.js
index ed4443c..5259093 100644
--- a/server/dev/app.js
+++ b/server/dev/app.js
@@ -5,18 +5,4 @@ module.exports = function(route, app) {
res.render('chat', {
});
});
-
- app.get(route+'/cookie', function(req, res) {
- var uid = function(n) {
- var chars='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789', nn='';
- for(var c=0; c < n; c++){
- nn += chars.substr(0|Math.random() * chars.length, 1);
- }
- return nn;
- };
- res.setHeader('Set-Cookie',
- cookie.serialize('sessionid', uid(40), {path: '/'})
- );
- res.send('cookie set');
- });
};
\ No newline at end of file
diff --git a/server/libs/daemon/daemon.cc b/server/libs/daemon/daemon.cc
deleted file mode 100644
index b9868ff..0000000
--- a/server/libs/daemon/daemon.cc
+++ /dev/null
@@ -1,301 +0,0 @@
-/*
-* Daemon.node
-*** A node.JS addon that allows creating Unix/Linux Daemons in pure Javascript.
-*** Copyright 2010 (c)
-* Under MIT License. See LICENSE file.
-*/
-
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-
-#define PID_MAXLEN 10
-
-using namespace v8;
-
-// Go through special routines to become a daemon.
-// if successful, returns daemon's PID
-Handle Start(const Arguments& args) {
- pid_t pid;
-
- pid = fork();
- if(pid > 0) exit(0);
- if(pid < 0) exit(1);
-
- // Can be changed after with process.umaks
- umask(0);
-
- setsid();
-
- // Can be changed with process.chdir
- chdir("/");
-
- return Integer::New(getpid());
-}
-
-// Close Standard IN/OUT/ERR Streams
-Handle CloseIO(const Arguments& args) {
- close(STDIN_FILENO);
- close(STDOUT_FILENO);
- close(STDERR_FILENO);
-}
-
-// File-lock to make sure that only one instance of daemon is running.. also for storing PID
-/* lock ( filename )
-*** filename: a path to a lock-file.
-*** Note: if filename doesn't exist, it will be created when function is called.
-*/
-Handle LockD(const Arguments& args) {
- if(!args[0]->IsString())
- return Boolean::New(false);
-
- String::Utf8Value data(args[0]->ToString());
- char pid_str[PID_MAXLEN+1];
-
- int lfp = open(*data, O_RDWR | O_CREAT, 0640);
- if(lfp < 0) exit(1);
- if(lockf(lfp, F_TLOCK, 0) < 0) exit(0);
-
- int len = snprintf(pid_str, PID_MAXLEN, "%d", getpid());
- write(lfp, pid_str, len);
-
- return Boolean::New(true);
-}
-
-class StreamPtr : public node::ObjectWrap
-{
-public:
- explicit StreamPtr(FILE** fpp, const char *pmode);
- ~StreamPtr();
-
- static Handle Open(const Arguments& args);
- static Handle Close(const Arguments& args);
- static Handle Redirect(const Arguments& args);
-
- static void Initialize(Handle