MCPcopy Create free account
hub / github.com/OpenSIPS/opensips / child_init

Function child_init

modules/rls/rls.c:528–548  ·  view source on GitHub ↗

* Initialize children */

Source from the content-addressed store, hash-verified

526 * Initialize children
527 */
528static int child_init(int rank)
529{
530 LM_DBG("child [%d] pid [%d]\n", rank, getpid());
531 if (rls_dbf.init==0)
532 {
533 LM_CRIT("database not bound\n");
534 return -1;
535 }
536 rls_db = rls_dbf.init(&db_url);
537 if (!rls_db)
538 {
539 LM_ERR("child %d: Error while connecting database\n",
540 rank);
541 return -1;
542 }
543
544 LM_DBG("child %d: Database connection opened successfully\n", rank);
545
546 pid= my_pid();
547 return 0;
548}
549
550/*
551 * destroy function

Callers 1

destroyFunction · 0.70

Calls 1

my_pidFunction · 0.85

Tested by

no test coverage detected