int main(int argc, char *argv[])
{

  CHECK_INIT_RETURN(itti_init(TASK_MAX, THREAD_MAX, MESSAGES_ID_MAX,
                              tasks_info, messages_info, messages_definition_xml,
                              mme_config.itti_config.log_file));
  /* Parse the command line for options and set the mme_config accordingly. */
  CHECK_INIT_RETURN(config_parse_opt_line(argc, argv, &mme_config) < 0);
  MSC_INIT(MSC_MME_GW, THREAD_MAX+TASK_MAX);

  /* Calling each layer init function */
  CHECK_INIT_RETURN(log_init(&mme_config, oai_epc_log_specific));
  CHECK_INIT_RETURN(nas_init(&mme_config));
  CHECK_INIT_RETURN(sctp_init(&mme_config));
  CHECK_INIT_RETURN(udp_init(&mme_config));
  CHECK_INIT_RETURN(gtpv1u_init(&mme_config));
  CHECK_INIT_RETURN(s1ap_mme_init(&mme_config));
  CHECK_INIT_RETURN(mme_app_init(&mme_config));
  CHECK_INIT_RETURN(s6a_init(&mme_config));
  CHECK_INIT_RETURN(sgw_lite_init(mme_config.config_file));
  /* Handle signals here */
  itti_wait_tasks_end();

  return 0;
}
int
main (
  int argc,
  char *argv[])
{
  memset (&hss_config, 0, sizeof (hss_config_t));

  if (hss_config_init (argc, argv, &hss_config) != 0) {
    return -1;
  }

  if (hss_mysql_connect (&hss_config) != 0) {
    return -1;
  }

  random_init ();

  if (hss_config.valid_op) {
    hss_mysql_check_opc_keys ((uint8_t *) hss_config.operator_key_bin);
  }

  s6a_init (&hss_config);

  while (1) {
    /*
     * TODO: handle signals here
     */
    sleep (1);
  }

  return 0;
}