• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ cut_remove_path函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: cut_setup

void
cut_setup(void)
{
  GError *error = NULL;
  memcached_return rc;

  tmp_directory = g_build_filename(grn_test_get_base_dir(), "tmp", NULL);
  cut_remove_path(tmp_directory, NULL);
  if (g_mkdir_with_parents(tmp_directory, 0700) == -1) {
    cut_assert_errno();
  }

  egg = gcut_egg_new(GROONGA, "-s",
                     "-p", GROONGA_TEST_PORT,
                     cut_take_printf("%s%s%s",
                                     tmp_directory,
                                     G_DIR_SEPARATOR_S,
                                     "memcached.db"),
                     NULL);
  gcut_egg_hatch(egg, &error);
  gcut_assert_error(error);

  sleep(1); /* wait for groonga daemon */
  memc = memcached_create(NULL);
  memcached_behavior_set(memc, MEMCACHED_BEHAVIOR_BINARY_PROTOCOL, 1);

  servers = memcached_servers_parse("localhost:" GROONGA_TEST_PORT);
  rc = memcached_server_push(memc, servers);

  cut_set_message("memcached server connect failed.");
  cut_assert_equal_int(MEMCACHED_SUCCESS, rc);

  memcached_flush(memc, 0); /* flush immediately for debug daemon */
}
开发者ID:ikdttr,项目名称:groonga,代码行数:34,代码来源:test-memcached.c


示例2: teardown

void
teardown (void)
{
    mz_config_free(config);

    cut_remove_path(config_path, NULL);
}
开发者ID:clear-code,项目名称:milter-zipcrypt,代码行数:7,代码来源:test-config.c


示例3: teardown_database

static void
teardown_database(void)
{
  grn_obj_close(&context, database);
  cut_remove_path(tmp_directory, NULL);
  g_free(tmp_directory);
}
开发者ID:AkioKanno,项目名称:groonga,代码行数:7,代码来源:test-cast-table.c


示例4: cut_teardown

void
cut_teardown(void)
{
    if (val1) {
        free(val1);
        val1 = NULL;
    }
    if (val2) {
        free(val2);
        val2 = NULL;
    }

    if (egg) {
        g_object_unref(egg);
    }

    cut_remove_path(tmp_directory, NULL);

    if (servers) {
        memcached_server_list_free(servers);
    }
    if (memc) {
        memcached_free(memc);
    }
}
开发者ID:hayamiz,项目名称:groonga,代码行数:25,代码来源:test-memcached.c


示例5: teardown

void
teardown (void)
{
  if (document)
    g_object_unref (document);

  if (expected_font_names)
    gcut_list_string_free (expected_font_names);
  if (actual_font_names)
    gcut_list_string_free (actual_font_names);

  if (expected_action_types)
    g_list_free (expected_font_names);
  if (actual_action_types)
    g_list_free (actual_font_names);

  if (tmp_dir)
    g_free (tmp_dir);

  if (tmp_base_dir)
    {
      cut_remove_path (tmp_base_dir, NULL);
      g_free (tmp_base_dir);
    }
}
开发者ID:kou,项目名称:poppler-test,代码行数:25,代码来源:test-document.c


示例6: cut_setup

void
cut_setup (void)
{
    config = milter_manager_configuration_new(NULL);
    loop = milter_test_event_loop_new();

    egg = NULL;
    another_egg = NULL;
    condition = NULL;

    expected_children = milter_manager_children_new(config, loop);
    actual_children = NULL;

    expected_load_paths = NULL;

    expected_eggs = NULL;
    expected_applicable_conditions = NULL;

    actual_xml = NULL;

    tmp_dir = g_build_filename(milter_test_get_base_dir(),
                               "tmp",
                               NULL);
    cut_remove_path(tmp_dir, NULL);
    if (g_mkdir_with_parents(tmp_dir, 0700) == -1)
        cut_assert_errno();
}
开发者ID:milter-manager,项目名称:milter-manager,代码行数:27,代码来源:test-configuration.c


示例7: cut_teardown

void
cut_teardown(void)
{
  grn_db_close(&context, database);
  grn_ctx_fin(&context);
  cut_remove_path(tmp_directory, NULL);
  g_free(path);
}
开发者ID:ikdttr,项目名称:groonga,代码行数:8,代码来源:test-expr.c


示例8: cut_setup

void
cut_setup(void)
{
  cut_remove_path(tmp_directory, NULL);
  g_mkdir_with_parents(tmp_directory, 0700);
  path = g_build_filename(tmp_directory, "text-expr", NULL);
  grn_ctx_init(&context, 0);
  database = grn_db_create(&context, path, NULL);
}
开发者ID:ikdttr,项目名称:groonga,代码行数:9,代码来源:test-expr.c


示例9: cut_teardown

void
cut_teardown(void)
{
  grn_obj_close(context, database);
  grn_ctx_fin(context);
  g_free(context);
  teardown_grn_logger(logger);
  cut_remove_path(tmp_directory, NULL);
}
开发者ID:temita,项目名称:groonga,代码行数:9,代码来源:test-table.c


示例10: setup

void
setup (void)
{
    actual_address = NULL;
    actual_address_size = 0;

    expected_error = NULL;
    actual_error = NULL;

    tmp_dir = g_build_filename(milter_test_get_base_dir(),
                               "tmp",
                               NULL);
    cut_remove_path(tmp_dir, NULL);
    if (g_mkdir_with_parents(tmp_dir, 0700) == -1)
        cut_assert_errno();
}
开发者ID:obache,项目名称:milter-manager,代码行数:16,代码来源:test-connection.c


示例11: cut_setup

void
cut_setup(void)
{
  db = NULL;
  context = g_new0(grn_ctx, 1);

  base_dir = g_build_filename(grn_test_get_base_dir(), "tmp", NULL);
  default_path = g_build_filename(base_dir, "db", NULL);
  default_encoding = GRN_ENC_DEFAULT;
  default_context_flags = GRN_CTX_USE_QL;

  cut_remove_path(base_dir, NULL);
  g_mkdir_with_parents(base_dir, 0755);

  sample_ql_program = g_build_filename(grn_test_get_base_dir(),
                                       "..", "ql", "bookmark.scm", NULL);
}
开发者ID:ikdttr,项目名称:groonga,代码行数:17,代码来源:test-public-context.c


示例12: cut_setup

void
cut_setup(void)
{
  cut_remove_path(tmp_directory, NULL);
  g_mkdir_with_parents(tmp_directory, 0700);
  path = g_build_filename(tmp_directory, "text-table-select", NULL);
  grn_ctx_init(&context, 0);
  database = grn_db_create(&context, path, NULL);

  cond = NULL;
  expr = NULL;
  res = NULL;

  GRN_TEXT_INIT(&text_buf, 0);
  GRN_UINT32_INIT(&int_buf, 0);
  GRN_PTR_INIT(&ptr_buf, 0, GRN_ID_NIL);
}
开发者ID:WEIC-DEV,项目名称:groonga,代码行数:17,代码来源:test-table-select.c


示例13: cut_setup

void
cut_setup(void)
{
  cut_remove_path(tmp_directory, NULL);
  g_mkdir_with_parents(tmp_directory, 0700);
  path = g_build_filename(tmp_directory, "text-expr", NULL);
  grn_ctx_init(&context, 0);
  database = grn_db_create(&context, path, NULL);

  expr = NULL;
  res = NULL;

  GRN_TEXT_INIT(&textbuf, 0);
  GRN_UINT32_INIT(&intbuf, 0);
  GRN_FLOAT_INIT(&floatbuf, 0);
  GRN_TIME_INIT(&timebuf, 0);
}
开发者ID:darashi,项目名称:groonga,代码行数:17,代码来源:test-expr-query.c


示例14: teardown

void
teardown (void)
{
    if (actual_address)
        g_free(actual_address);

    if (expected_error)
        g_error_free(expected_error);
    if (actual_error)
        g_error_free(actual_error);

    if (tmp_dir) {
        g_chmod(tmp_dir, 0755);
        cut_remove_path(tmp_dir, NULL);
        g_free(tmp_dir);
    }
}
开发者ID:obache,项目名称:milter-manager,代码行数:17,代码来源:test-connection.c


示例15: cut_teardown

void
cut_teardown(void)
{
  grn_obj_unlink(context, &buffer);
  if (column) {
    grn_obj_unlink(context, column);
  }
  if (table) {
    grn_obj_unlink(context, table);
  }

  grn_obj_close(context, database);
  grn_ctx_fin(context);
  g_free(context);

  teardown_grn_logger(logger);
  cut_remove_path(tmp_directory, NULL);
}
开发者ID:cosmo0920,项目名称:groonga,代码行数:18,代码来源:test-table.c


示例16: cut_teardown

void
cut_teardown(void)
{
  grn_obj_close(&context, &text_buf);
  grn_obj_close(&context, &int_buf);
  grn_obj_close(&context, &ptr_buf);

  if (res)
    grn_obj_close(&context, res);
  if (expr)
    grn_obj_close(&context, expr);
  if (cond)
    grn_obj_close(&context, cond);

  grn_obj_close(&context, database);
  grn_ctx_fin(&context);
  cut_remove_path(tmp_directory, NULL);
  g_free(path);
}
开发者ID:WEIC-DEV,项目名称:groonga,代码行数:19,代码来源:test-table-select.c


示例17: setup

void
setup (void)
{
  document = NULL;

  expected_font_names = NULL;
  actual_font_names = NULL;

  expected_action_types = NULL;
  actual_action_types = NULL;

  cut_set_fixture_data_dir (poppler_test_get_base_dir (),
                            "fixtures",
                            "pdf",
                            NULL);

  tmp_base_dir = g_build_filename (poppler_test_get_base_dir (), "tmp", NULL);
  cut_remove_path (tmp_base_dir, NULL);

  tmp_dir = g_build_filename (tmp_base_dir, "document", NULL);
  g_mkdir_with_parents (tmp_dir, 0755);
}
开发者ID:kou,项目名称:poppler-test,代码行数:22,代码来源:test-document.c


示例18: cut_teardown

void
cut_teardown(void)
{
  if (context) {
    if (db) {
      grn_obj_close(context, db);
    }
    grn_ctx_fin(context);
    g_free(context);
  }

  if (default_path) {
    g_free(default_path);
  }

  if (base_dir) {
    cut_remove_path(base_dir, NULL);
  }

  if (sample_ql_program) {
    g_free(sample_ql_program);
  }
}
开发者ID:AkioKanno,项目名称:groonga,代码行数:23,代码来源:test-public-context.c


示例19: cut_teardown

void
cut_teardown (void)
{
    if (config)
        g_object_unref(config);
    if (loop)
        g_object_unref(loop);
    if (egg)
        g_object_unref(egg);
    if (another_egg)
        g_object_unref(another_egg);
    if (condition)
        g_object_unref(condition);

    if (expected_children)
        g_object_unref(expected_children);
    if (actual_children)
        g_object_unref(actual_children);

    if (expected_load_paths) {
        g_list_foreach(expected_load_paths, (GFunc)g_free, NULL);
        g_list_free(expected_load_paths);
    }

    if (expected_eggs)
        g_list_free(expected_eggs);
    if (expected_applicable_conditions)
        g_list_free(expected_applicable_conditions);

    if (actual_xml)
        g_free(actual_xml);

    if (tmp_dir) {
        cut_remove_path(tmp_dir, NULL);
        g_free(tmp_dir);
    }
}
开发者ID:milter-manager,项目名称:milter-manager,代码行数:37,代码来源:test-configuration.c


示例20: cut_teardown

void
cut_teardown (void)
{
    if (idle_id > 0)
        milter_event_loop_remove(loop, idle_id);
    if (idle_shutdown_id > 0)
        milter_event_loop_remove(loop, idle_shutdown_id);

    if (server)
        g_object_unref(server);
    if (client)
        g_object_unref(client);

    if (decoder)
        g_object_unref(decoder);
    if (encoder)
        g_object_unref(encoder);

    if (option)
        g_object_unref(option);
    if (negotiate_option)
        g_object_unref(negotiate_option);

    if (macros_requests)
        g_object_unref(macros_requests);
    if (negotiate_macros_requests)
        g_object_unref(negotiate_macros_requests);

    if (connect_host_name)
        g_free(connect_host_name);
    if (connect_address)
        g_free(connect_address);

    if (helo_fqdn)
        g_free(helo_fqdn);

    if (envelope_from)
        g_free(envelope_from);

    if (envelope_recipient_to)
        g_free(envelope_recipient_to);

    if (header_name)
        g_free(header_name);
    if (header_value)
        g_free(header_value);

    if (body_chunk)
        g_free(body_chunk);

    if (unknown_command)
        g_free(unknown_command);

    if (actual_error)
        g_error_free(actual_error);
    if (expected_error)
        g_error_free(expected_error);

    if (tmp_dir) {
        cut_remove_path(tmp_dir, NULL);
        g_free(tmp_dir);
    }
}
开发者ID:milter-manager,项目名称:milter-manager,代码行数:63,代码来源:test-client.c



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ cutilCheckError函数代码示例发布时间:2022-05-30
下一篇:
C++ cut_message函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap