Commit 79f269cb authored by unknown's avatar unknown

Daemon code to run on all unixes

parent 3f46ae17
......@@ -18,11 +18,10 @@
#include "NdbDaemon.h"
#define NdbDaemon_ErrorSize 500
#if defined(NDB_LINUX) || defined(NDB_SOLARIS)
/* XXX fix other unixes */
long NdbDaemon_DaemonPid;
int NdbDaemon_ErrorCode;
char NdbDaemon_ErrorText[NdbDaemon_ErrorSize];
int
NdbDaemon_Make(const char* lockfile, const char* logfile, unsigned flags)
{
......@@ -130,7 +129,8 @@ NdbDaemon_Make(const char* lockfile, const char* logfile, unsigned flags)
/* Success */
return 0;
}
#else
#if 0
int
NdbDaemon_Make(const char* lockfile, const char* logfile, unsigned flags)
{
......
......@@ -14,6 +14,7 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <ndb_global.h>
#include "NdbDaemon.h"
#define NdbDaemon_ErrorSize 500
......@@ -24,8 +25,10 @@ char NdbDaemon_ErrorText[NdbDaemon_ErrorSize];
int
NdbDaemon_Make(const char* lockfile, const char* logfile, unsigned flags)
{
// XXX do something
return 0;
/* Fail */
snprintf(NdbDaemon_ErrorText, NdbDaemon_ErrorSize,
"Daemon mode not implemented");
return -1;
}
#ifdef NDB_DAEMON_TEST
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment