Commit 77f9069c authored by tomas@mc05.(none)'s avatar tomas@mc05.(none)

Daemon code to run on all unixes

parent ac92bd58
......@@ -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