delete useless code
This commit is contained in:
67
mms/main.c
67
mms/main.c
@@ -26,9 +26,8 @@ extern pthread_mutex_t mtx;
|
||||
extern pt61850app_t *g_pt61850app;
|
||||
extern node_t *g_node;
|
||||
char g_my_conf_fname[256];
|
||||
//extern byte_t g_Master;
|
||||
|
||||
char g_onlyIP[255]; //ֱ<><D6B1>ij<EFBFBD><C4B3>IP<49><50><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><CEAA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
//extern byte_t g_protect_file; //0:<3A><><EFBFBD>ٻ<EFBFBD><D9BB><EFBFBD><EFBFBD><EFBFBD>¼<EFBFBD><C2BC><EFBFBD>ļ<EFBFBD> 1:<3A>ٻ<EFBFBD><D9BB><EFBFBD><EFBFBD><EFBFBD>¼<EFBFBD><C2BC><EFBFBD>ļ<EFBFBD>
|
||||
|
||||
apr_pool_t *g_root_pool;
|
||||
apr_pool_t *g_rdb_pool;
|
||||
@@ -122,7 +121,6 @@ void init_daemon(void)
|
||||
//"--subdir, set the subdir of /CloudForward/ as the working directory, \n"
|
||||
int usage()
|
||||
{
|
||||
// fprintf(stderr,"\n\n******** IEC61850 Protocol ********\n");
|
||||
fprintf(stderr,"\nUsage : pt61850netd_pqfe -d [subdir] \n");
|
||||
|
||||
exit(-1);
|
||||
@@ -179,16 +177,9 @@ int prepare_entironment_2()
|
||||
return (-1);
|
||||
}
|
||||
|
||||
//g_fun_pool = 0;
|
||||
|
||||
//rv = apr_thread_mutex_create(&g_rdb_mutex, APR_THREAD_MUTEX_NESTED,g_root_pool);//<2F><><EFBFBD><EFBFBD>RDB<44><42>
|
||||
//if ( rv != APR_SUCCESS) {
|
||||
// return rv;
|
||||
//}
|
||||
/* Initialize the register table. Call these functions first! */
|
||||
echo_msg1("%-60s","Initialize system register......");
|
||||
//init_default_dbparser_table(); //<2F><><EFBFBD>ݸ<EFBFBD>XML<4D>ļ<EFBFBD><C4BC><EFBFBD><EFBFBD><EFBFBD>RDB<44><42>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD>
|
||||
//load_driver_library(); //<2F><><EFBFBD>ø<EFBFBD><C3B8>˿<EFBFBD><CBBF><EFBFBD><EFBFBD><EFBFBD>
|
||||
|
||||
echo_msg("OK\n\n");
|
||||
|
||||
initTimezoneOffset();
|
||||
@@ -211,11 +202,8 @@ void printf_cur_user()
|
||||
int main(int argc, const char **argv)
|
||||
{
|
||||
|
||||
// ipcclient_t *ipcclient = NULL;
|
||||
// void *cookie = NULL;
|
||||
uint32_t stimer = 1;
|
||||
apr_status_t rv;
|
||||
// int pid;
|
||||
|
||||
/* Prepare the system context */
|
||||
rv=prepare_entironment_2();
|
||||
@@ -225,22 +213,6 @@ int main(int argc, const char **argv)
|
||||
|
||||
getVersion(argc,argv);
|
||||
|
||||
////////////////////
|
||||
//WW <20><><EFBFBD><EFBFBD>json
|
||||
//TestJson(NULL);
|
||||
//WW 2023-08-31 end
|
||||
///////////////////
|
||||
//TestSMSPost();//WW 2023-08-28<32><38><EFBFBD>Թ<EFBFBD>˾post
|
||||
//TestBodyPost();
|
||||
//TestToken();//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Դҵ<D4B4><D2B5><EFBFBD><EFBFBD>̨
|
||||
|
||||
////////////////////
|
||||
//WW <20><><EFBFBD><EFBFBD>json
|
||||
//TestOSS();
|
||||
//TestOBS();
|
||||
//WW 2023-09-01 end
|
||||
///////////////////
|
||||
/* Parse the command-line parameter */
|
||||
rv=parse_param(argc, argv);
|
||||
if (rv!=APR_SUCCESS){
|
||||
return rv;
|
||||
@@ -280,9 +252,6 @@ int main(int argc, const char **argv)
|
||||
return rv;
|
||||
}
|
||||
|
||||
//lnk20241024ȥ<34><C8A5><EFBFBD><EFBFBD><EFBFBD>ݿ<EFBFBD><DDBF><EFBFBD><EFBFBD><EFBFBD>
|
||||
//OTLConnect();
|
||||
|
||||
rv = run_protocol();
|
||||
if (rv!=APR_SUCCESS){
|
||||
return rv;
|
||||
@@ -360,10 +329,8 @@ int parse_param(int argc, const char **argv)
|
||||
|
||||
char *p;
|
||||
char temp[128];
|
||||
//int g_front_seg_index, g_front_seg_num;
|
||||
/* Set default command-line parameter */
|
||||
|
||||
g_node_id = 0;
|
||||
//g_protect_file = 0;
|
||||
|
||||
echo_warn2("================= compiled@ %s %s =================\n",__DATE__ , __TIME__ );
|
||||
|
||||
@@ -383,18 +350,7 @@ int parse_param(int argc, const char **argv)
|
||||
break;
|
||||
case 'R':
|
||||
case 'r':
|
||||
// if (opt_arg[0] >= '0' && opt_arg[0] <= '9' )
|
||||
// {
|
||||
// g_client_id = atoi(opt_arg);
|
||||
// if (g_client_id>2||g_client_id<0)
|
||||
// {
|
||||
// printf("Do not support triple or above clients \n ");
|
||||
// return (usage());
|
||||
// }
|
||||
////g_auto_client_id = FALSE;
|
||||
// }
|
||||
// else
|
||||
// return (usage());
|
||||
|
||||
break;
|
||||
case 's':
|
||||
case 'S':
|
||||
@@ -413,11 +369,6 @@ int parse_param(int argc, const char **argv)
|
||||
|
||||
printf("g_front_seg_num:%d",g_front_seg_num);
|
||||
|
||||
//echo_warn2("================= compiled@ %d %d =================\n", g_front_seg_index, g_front_seg_num);
|
||||
//lnk20241206<30><36><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA>¼subdir<69><72><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʹ<EFBFBD><CAB9>
|
||||
//echo_warn1("subdir %s ", opt_arg + 6);
|
||||
//strcpy(subdir, opt_arg + 6);
|
||||
|
||||
break;
|
||||
break;
|
||||
case 'a':
|
||||
@@ -433,14 +384,7 @@ int parse_param(int argc, const char **argv)
|
||||
break;
|
||||
case 'f':
|
||||
case 'F':
|
||||
//if (opt_arg[strlen(opt_arg)-1] == '/'
|
||||
// || opt_arg[strlen(opt_arg)-1] == '\\') {
|
||||
// echo_errg( "Error: Bad or invalid file name");
|
||||
// return (usage());
|
||||
// }
|
||||
// //g_my_conf_fname = SHR_GetPrivateFileName(opt_arg,g_root_pool);
|
||||
// echo_warn1("using config file %s!\n", g_my_conf_fname);
|
||||
// break;
|
||||
break;
|
||||
case 'P':
|
||||
case 'p':
|
||||
if (opt_arg[0] >= '0' && opt_arg[0] <= '9' ) {
|
||||
@@ -459,7 +403,6 @@ int parse_param(int argc, const char **argv)
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////<2F><><EFBFBD>Ӳ<EFBFBD><D3B2>Խ<EFBFBD><D4BD>̵ļ<CCB5><C4BC>غ<EFBFBD><D8BA><EFBFBD>lnk20250304
|
||||
void doMonitorTaskmain(void) {
|
||||
static int stimer = 0;
|
||||
|
||||
Reference in New Issue
Block a user