当前位置: 首页>>代码示例>>C++>>正文


C++ DEBUG_INIT函数代码示例

本文整理汇总了C++中DEBUG_INIT函数的典型用法代码示例。如果您正苦于以下问题:C++ DEBUG_INIT函数的具体用法?C++ DEBUG_INIT怎么用?C++ DEBUG_INIT使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了DEBUG_INIT函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: main

int main(int argc, char * argv[])
{
    DEBUG_INIT(NULL);
    volatile struct exception exp;
    TRY_CATCH(exp, MASK_ALL) {
        wrapper_main(argc, argv);
    }
开发者ID:pi3orama,项目名称:currf2,代码行数:7,代码来源:test_wrapper.c

示例2: gst_vdp_output_buffer_get_type

GType
gst_vdp_output_buffer_get_type (void)
{
  static GType _gst_vdp_output_buffer_type;

  if (G_UNLIKELY (_gst_vdp_output_buffer_type == 0)) {
    static const GTypeInfo info = {
      sizeof (GstBufferClass),
      NULL,
      NULL,
      gst_vdp_output_buffer_class_init,
      NULL,
      NULL,
      sizeof (GstVdpOutputBuffer),
      0,
      (GInstanceInitFunc) gst_vdp_output_buffer_init,
      NULL
    };
    _gst_vdp_output_buffer_type = g_type_register_static (GST_TYPE_BUFFER,
        "GstVdpOutputBuffer", &info, 0);

    DEBUG_INIT ();
  }
  return _gst_vdp_output_buffer_type;
}
开发者ID:zsx,项目名称:ossbuild,代码行数:25,代码来源:gstvdpoutputbuffer.c

示例3: main

int main()
{
  DDRA = 0xff;
  DDRB = 0x00;
  PORTB = 0x00;
  DDRB |= _BV(EMPH_BIT);
  DEBUG_INIT();
  timer_init();
  sei();

  uint8_t leds = 1;

  for (;;) {
    PORTA = leds;
    delayms(250);
    delayms(250);
    if (!(leds <<= 1))
	leds++;

    service_ide();

    if (SDCARD_INSERTED)
      handle_sdcard();
  }

  return 0;
}
开发者ID:zeldin,项目名称:iceGDROM,代码行数:27,代码来源:main.c

示例4: gst_vdp_mpeg_frame_get_type

GType
gst_vdp_mpeg_frame_get_type (void)
{
  static GType _gst_vdp_mpeg_frame_type = 0;

  if (G_UNLIKELY (_gst_vdp_mpeg_frame_type == 0)) {
    static const GTypeInfo info = {
      sizeof (GstVdpMpegFrameClass),
      NULL,
      NULL,
      gst_vdp_mpeg_frame_class_init,
      NULL,
      NULL,
      sizeof (GstVdpMpegFrame),
      0,
      (GInstanceInitFunc) gst_vdp_mpeg_frame_init,
      NULL
    };
    _gst_vdp_mpeg_frame_type = g_type_register_static (GST_TYPE_VIDEO_FRAME,
        "GstVdpMpegFrame", &info, 0);

    DEBUG_INIT ();
  }
  return _gst_vdp_mpeg_frame_type;
}
开发者ID:spunktsch,项目名称:svtplayer,代码行数:25,代码来源:gstvdpmpegframe.c

示例5: main

int main(int argc, const char *argv[])
{
    int opt;
    poptContext pc;
    struct main_context *main_ctx;
    int ret;
    uid_t uid;
    gid_t gid;

    struct poptOption long_options[] = {
        POPT_AUTOHELP
        SSSD_MAIN_OPTS
        SSSD_SERVER_OPTS(uid, gid)
        POPT_TABLEEND
    };

    /* Set debug level to invalid value so we can decide if -d 0 was used. */
    debug_level = SSSDBG_INVALID;

    umask(DFL_RSP_UMASK);

    pc = poptGetContext(argv[0], argc, argv, long_options, 0);
    while((opt = poptGetNextOpt(pc)) != -1) {
        switch(opt) {
        default:
            fprintf(stderr, "\nInvalid option %s: %s\n\n",
                  poptBadOption(pc, 0), poptStrerror(opt));
            poptPrintUsage(pc, stderr, 0);
            return 1;
        }
    }

    poptFreeContext(pc);

    DEBUG_INIT(debug_level);

    /* set up things like debug, signals, daemonization, etc... */
    debug_log_file = "sssd_pac";

    ret = server_setup("sssd[pac]", 0, uid, gid,
                       CONFDB_PAC_CONF_ENTRY, &main_ctx);
    if (ret != EOK) return 2;

    ret = die_if_parent_died();
    if (ret != EOK) {
        /* This is not fatal, don't return */
        DEBUG(SSSDBG_OP_FAILURE, "Could not set up to exit when parent process does\n");
    }

    ret = pac_process_init(main_ctx,
                           main_ctx->event_ctx,
                           main_ctx->confdb_ctx);
    if (ret != EOK) return 3;

    /* loop on main */
    server_loop(main_ctx);

    return 0;
}
开发者ID:lejonet,项目名称:sssd,代码行数:59,代码来源:pacsrv.c

示例6: main

int main(int argc, const char *argv[])
{
    int rv;
    int no_cleanup = 0;
    poptContext pc;
    int opt;
    struct poptOption long_options[] = {
        POPT_AUTOHELP
        SSSD_DEBUG_OPTS
        {"no-cleanup", 'n', POPT_ARG_NONE, &no_cleanup, 0,
         _("Do not delete the test database after a test run"), NULL },
        POPT_TABLEEND
    };

    const UnitTest tests[] = {
        /* Utility functions unit test */
        unit_test(dyndns_test_get_ifaddr),

        /* Dynamic DNS update unit tests*/
        unit_test_setup_teardown(dyndns_test_ok,
                                 dyndns_test_setup, dyndns_test_teardown),
        unit_test_setup_teardown(dyndns_test_error,
                                 dyndns_test_setup, dyndns_test_teardown),
        unit_test_setup_teardown(dyndns_test_timeout,
                                 dyndns_test_setup, dyndns_test_teardown),
        unit_test_setup_teardown(dyndns_test_interval,
                                 dyndns_test_setup, dyndns_test_teardown),
    };

    /* Set debug level to invalid value so we can deside if -d 0 was used. */
    debug_level = SSSDBG_INVALID;

    pc = poptGetContext(argv[0], argc, argv, long_options, 0);
    while((opt = poptGetNextOpt(pc)) != -1) {
        switch(opt) {
        default:
            fprintf(stderr, "\nInvalid option %s: %s\n\n",
                    poptBadOption(pc, 0), poptStrerror(opt));
            poptPrintUsage(pc, stderr, 0);
            return 1;
        }
    }
    poptFreeContext(pc);

    DEBUG_INIT(debug_level);

    /* Even though normally the tests should clean up after themselves
     * they might not after a failed run. Remove the old db to be sure */
    tests_set_cwd();
    test_dom_suite_cleanup(TESTS_PATH, TEST_CONF_DB, TEST_SYSDB_FILE);
    test_dom_suite_setup(TESTS_PATH);

    rv = run_tests(tests);
    if (rv == 0 && !no_cleanup) {
        test_dom_suite_cleanup(TESTS_PATH, TEST_CONF_DB, TEST_SYSDB_FILE);
    }
    return rv;
}
开发者ID:AbhishekKumarSingh,项目名称:sssd,代码行数:58,代码来源:test_dyndns.c

示例7: main

int main (void){
	DEBUG_INIT();
	cli_rx = (cli_rx_fpt)uart0_getc;
	cli_tx = (cli_tx_fpt)uart0_putc;	 	
	for(;;){
		cli_putstr_P(PSTR("\r\n\r\nCrypto-VS ("));
		cli_putstr(algo_name);
		cli_putstr_P(PSTR(")\r\nloaded and running\r\n"));
		cmd_interface(cmdlist);
	}
}
开发者ID:EwanLu,项目名称:chipwhisperer,代码行数:11,代码来源:main-hmac-md5-test.c

示例8: main

int main (void){
	DEBUG_INIT();
	uart_putstr("\r\n");
	cli_rx = uart_getc;
	cli_tx = uart_putc;	 	
	shavs_algolist=(hfdesc_t**)algolist;
	shavs_algo=(hfdesc_t*)&sha256_desc;
	for(;;){
		uart_putstr_P(PSTR("\r\n\r\nCrypto-VS ("));
		uart_putstr(algo_name);
		uart_putstr_P(PSTR(")\r\nloaded and running\r\n"));
		cmd_interface(cmdlist);
	}
}
开发者ID:azilly-de,项目名称:openkubus,代码行数:14,代码来源:main-sha256-test.c

示例9: main

int main (void){
	DEBUG_INIT();

	cli_rx = (cli_rx_fpt)uart0_getc;
	cli_tx = (cli_tx_fpt)uart0_putc;
	cmacvs_algolist=(bcdesc_t**)algolist;
	cmacvs_algo=(bcdesc_t*)&aes128_desc;
	for(;;){
		cli_putstr_P(PSTR("\r\n\r\nCrypto-VS ("));
		cli_putstr(algo_name);
		cli_putstr_P(PSTR(")\r\nloaded and running\r\n"));
		cmd_interface(cmdlist);
	}
}
开发者ID:kailiu-bupt2005,项目名称:Arduino-and-XBee-based-secure-home-automation,代码行数:14,代码来源:main-aes-test.c

示例10: gst_vdp_sink_get_type

GType
gst_vdp_sink_get_type (void)
{
  static GType vdp_sink_type = 0;

  if (!vdp_sink_type) {
    static const GTypeInfo vdp_sink_info = {
      sizeof (VdpSinkClass),
      gst_vdp_sink_base_init,
      NULL,
      (GClassInitFunc) gst_vdp_sink_class_init,
      NULL,
      NULL,
      sizeof (VdpSink),
      0,
      (GInstanceInitFunc) gst_vdp_sink_init,
    };
    static const GInterfaceInfo iface_info = {
      (GInterfaceInitFunc) gst_vdp_sink_interface_init,
      NULL,
      NULL,
    };
    static const GInterfaceInfo navigation_info = {
      (GInterfaceInitFunc) gst_vdp_sink_navigation_init,
      NULL,
      NULL,
    };
    static const GInterfaceInfo overlay_info = {
      (GInterfaceInitFunc) gst_vdp_sink_xoverlay_init,
      NULL,
      NULL,
    };

    vdp_sink_type = g_type_register_static (GST_TYPE_VIDEO_SINK,
        "VdpSink", &vdp_sink_info, 0);

    g_type_add_interface_static (vdp_sink_type, GST_TYPE_IMPLEMENTS_INTERFACE,
        &iface_info);
    g_type_add_interface_static (vdp_sink_type, GST_TYPE_NAVIGATION,
        &navigation_info);
    g_type_add_interface_static (vdp_sink_type, GST_TYPE_X_OVERLAY,
        &overlay_info);
  }

  DEBUG_INIT ();

  return vdp_sink_type;
}
开发者ID:spunktsch,项目名称:svtplayer,代码行数:48,代码来源:gstvdpsink.c

示例11: main

int main(void)
{
		//initialize_memory();
        DEBUG_INIT();
#if ! defined(USE_SCHEDULE)
	bus_init();
	ifs_init();
#endif /* USE_SCHEDULE */
	ttpa_setstate(TTPA_STATE_UNSYNC);
        while(1) {
#if defined(USE_SCHEDULE)
		schedule();
#endif
        }
    return 0;
}
开发者ID:bruggers,项目名称:NES-2012,代码行数:16,代码来源:main.c

示例12: main

int main(void)
{
   int i;

   DEBUG_INIT("debug_test");

   PAF;

   for(i=0;i<100;i++)
      test1(i);

   for(i=0;i<100;i++)
      test2(i);

   PIF;

   exit(0);
}
开发者ID:sambeau,项目名称:burp,代码行数:18,代码来源:debug.c

示例13: main

int main (void){
	DEBUG_INIT();

	cli_rx = (cli_rx_fpt)uart0_getc;
	cli_tx = (cli_tx_fpt)uart0_putc;
	shavs_algolist=(hfdesc_t**)algolist;
	shavs_algo=(hfdesc_t*)&echo256_desc;
	for(;;){
		cli_putstr_P(PSTR("\r\n\r\nCrypto-VS ("));
		cli_putstr(algo_name);
		cli_putstr_P(PSTR("; "));
		cli_putstr(__DATE__);
		cli_putstr_P(PSTR(" "));
		cli_putstr(__TIME__);
		cli_putstr_P(PSTR(")\r\nloaded and running\r\n"));

		cmd_interface(cmdlist);
	}
}
开发者ID:EwanLu,项目名称:chipwhisperer,代码行数:19,代码来源:main-echo-test.c

示例14: main

int
main(int argc, char * argv[])
{
	char * target_fn = NULL;
	DEBUG_INIT(NULL);
	opts = parse_args(argc, argv);
	assert(opts != NULL);

	target_fn = argv[opts->cmd_idx];
	assert(opts->cmd_idx < argc);

	/* check ckpt file and target file */
	struct stat s;
	if (stat(opts->ckpt_fn, &s) != 0) {
		SYS_ERROR("file %s doesn't exists\n", opts->ckpt_fn);
		return -1;
	}

	if (!S_ISREG(s.st_mode)) {
		SYS_ERROR("file %s not a regular file\n", opts->ckpt_fn);
		return -1;
	}

	if (stat(target_fn, &s) != 0) {
		SYS_ERROR("file %s doesn't exists\n", target_fn);
		return -1;
	}

	if (!S_ISREG(s.st_mode)) {
		SYS_ERROR("file %s not a regular file\n", target_fn);
		return -1;
	}


	/* start */
	volatile struct exception exp;
	TRY_CATCH(exp, MASK_ALL) {
		cf = load_ckpt_file(opts->ckpt_fn);
		gdbloader_main(target_fn);
		close_ckpt_file(cf);
		ptrace_detach(TRUE);
	} CATCH (exp) {
开发者ID:pi3orama,项目名称:Snitchaser,代码行数:42,代码来源:gdbloader.c

示例15: main

int main(int argc, const char *argv[])
{
    int opt;
    poptContext pc;
    int number_failed;

    struct poptOption long_options[] = {
        POPT_AUTOHELP
        { "debug-level", 'd', POPT_ARG_INT, &debug_level, 0, "Set debug level", NULL },
        POPT_TABLEEND
    };

    /* Set debug level to invalid value so we can deside if -d 0 was used. */
    debug_level = SSSDBG_INVALID;

    pc = poptGetContext(argv[0], argc, argv, long_options, 0);
    while((opt = poptGetNextOpt(pc)) != -1) {
        switch(opt) {
        default:
            fprintf(stderr, "\nInvalid option %s: %s\n\n",
                    poptBadOption(pc, 0), poptStrerror(opt));
            poptPrintUsage(pc, stderr, 0);
            return 1;
        }
    }
    poptFreeContext(pc);

    DEBUG_INIT(debug_level);

    tests_set_cwd();

    Suite *s = crypto_suite();
    SRunner *sr = srunner_create(s);
    srunner_run_all(sr, CK_ENV);
    number_failed = srunner_ntests_failed(sr);
    srunner_free(sr);

    return (number_failed == 0 ? EXIT_SUCCESS : EXIT_FAILURE);
}
开发者ID:AbhishekKumarSingh,项目名称:sssd,代码行数:39,代码来源:crypto-tests.c


注:本文中的DEBUG_INIT函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。