| 14 |
* * |
* * |
| 15 |
***************************************************************************/ |
***************************************************************************/ |
| 16 |
|
|
|
#include "init.h" |
|
|
#include "database.h" |
|
| 17 |
#include "bbs.h" |
#include "bbs.h" |
| 18 |
#include "common.h" |
#include "common.h" |
| 19 |
#include "log.h" |
#include "database.h" |
| 20 |
|
#include "init.h" |
| 21 |
#include "io.h" |
#include "io.h" |
| 22 |
#include <string.h> |
#include "log.h" |
|
#include <stdlib.h> |
|
| 23 |
#include <signal.h> |
#include <signal.h> |
| 24 |
|
#include <stdlib.h> |
| 25 |
|
#include <string.h> |
| 26 |
|
#include <unistd.h> |
| 27 |
#include <sys/param.h> |
#include <sys/param.h> |
|
#include <sys/types.h> |
|
| 28 |
#include <sys/stat.h> |
#include <sys/stat.h> |
| 29 |
#include <unistd.h> |
#include <sys/types.h> |
| 30 |
|
|
| 31 |
#define CONF_DELIM_WITH_SPACE " \t\r\n" |
#define CONF_DELIM_WITH_SPACE " \t\r\n" |
| 32 |
|
|
| 130 |
} |
} |
| 131 |
else if (strcasecmp(p, "bbs_port") == 0) |
else if (strcasecmp(p, "bbs_port") == 0) |
| 132 |
{ |
{ |
| 133 |
BBS_port = (in_port_t)atoi(q); |
BBS_port[0] = (in_port_t)atoi(q); |
| 134 |
} |
} |
| 135 |
else if (strcasecmp(p, "bbs_ssh") == 0) |
else if (strcasecmp(p, "bbs_ssh_port") == 0) |
| 136 |
{ |
{ |
| 137 |
SSH_v2 = (strcasecmp(q, "v2") == 0 ? 1 : 0); |
BBS_port[1] = (in_port_t)atoi(q); |
| 138 |
} |
} |
| 139 |
else if (strcasecmp(p, "bbs_max_client") == 0) |
else if (strcasecmp(p, "bbs_max_client") == 0) |
| 140 |
{ |
{ |
| 174 |
log_error("Ignore config bbs_start_dt with incorrect value\n"); |
log_error("Ignore config bbs_start_dt with incorrect value\n"); |
| 175 |
continue; |
continue; |
| 176 |
} |
} |
| 177 |
snprintf(BBS_start_dt, sizeof(BBS_start_dt), "%4sÄê%2sÔÂ%2sÈÕ", y, m, d); |
snprintf(BBS_start_dt, sizeof(BBS_start_dt), "%4s年%2s月%2s日", y, m, d); |
| 178 |
} |
} |
| 179 |
else if (strcasecmp(p, "db_host") == 0) |
else if (strcasecmp(p, "db_host") == 0) |
| 180 |
{ |
{ |