资源简介
C语言标准库函数源码大全,相当全的库函数源码,各种源码库函数,是学习C语言,精通C语言的资料工具,望能帮助大家学习c语言.
代码片段和文件信息
/* Skeleton for test programs.
Copyright (C) 1998-2014 Free Software Foundation Inc.
This file is part of the GNU C Library.
Contributed by Ulrich Drepper 1998.
The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License or (at your option) any later version.
The GNU C Library is distributed in the hope that it will be useful
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with the GNU C Library; if not see
. */
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
/* The test function is normally called ‘do_test‘ and it is called
with argc and argv as the arguments. We nevertheless provide the
possibility to overwrite this name. */
#ifndef TEST_FUNCTION
# define TEST_FUNCTION do_test (argc argv)
#endif
#ifndef TEST_DATA_LIMIT
# define TEST_DATA_LIMIT (64 << 20) /* Data limit (bytes) to run with. */
#endif
#define OPT_DIRECT 1000
#define OPT_TESTDIR 1001
static struct option options[] =
{
#ifdef CMDLINE_OPTIONS
CMDLINE_OPTIONS
#endif
{ “direct“ no_argument NULL OPT_DIRECT }
{ “test-dir“ required_argument NULL OPT_TESTDIR }
{ NULL 0 NULL 0 }
};
/* PID of the test itself. */
static pid_t pid;
/* Directory to place temporary files in. */
static const char *test_dir;
/* List of temporary files. */
struct temp_name_list
{
struct qelem q;
const char *name;
} *temp_name_list;
/* Add temporary files in list. */
static void
__attribute__ ((unused))
add_temp_file (const char *name)
{
struct temp_name_list *newp
= (struct temp_name_list *) calloc (sizeof (*newp) 1);
if (newp != NULL)
{
newp->name = name;
if (temp_name_list == NULL)
temp_name_list = (struct temp_name_list *) &newp->q;
else
insque (newp temp_name_list);
}
}
/* Delete all temporary files. */
static void
delete_temp_files (void)
{
while (temp_name_list != NULL)
{
remove (temp_name_list->name);
temp_name_list = (struct temp_name_list *) temp_name_list->q.q_forw;
}
}
/* Create a temporary file. */
static int
__attribute__ ((unused))
create_temp_file (const char *base char **filename)
{
char *fname;
int fd;
fname = (char *) malloc (strlen (test_dir) + 1 + strlen (base)
+ sizeof (“XXXXXX“));
if (fname == NULL)
{
puts (“out of memory“);
return -1;
}
strcpy (stpcpy (stpcpy (stpcpy (fname te
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 23 2014-02-07 17:04 glibc-2.19\.gitattributes
文件 317 2014-02-07 17:04 glibc-2.19\.gitignore
文件 1230 2014-02-07 17:04 glibc-2.19\abi-tags
文件 9097 2014-02-07 17:04 glibc-2.19\aclocal.m4
文件 1242 2014-02-07 17:04 glibc-2.19\argp\argp-ba.c
文件 1192 2014-02-07 17:04 glibc-2.19\argp\argp-eexst.c
文件 11260 2014-02-07 17:04 glibc-2.19\argp\argp-fmtstream.c
文件 10758 2014-02-07 17:04 glibc-2.19\argp\argp-fmtstream.h
文件 1634 2014-02-07 17:04 glibc-2.19\argp\argp-fs-xinl.c
文件 55607 2014-02-07 17:04 glibc-2.19\argp\argp-help.c
文件 5404 2014-02-07 17:04 glibc-2.19\argp\argp-namefrob.h
文件 29181 2014-02-07 17:04 glibc-2.19\argp\argp-parse.c
文件 1213 2014-02-07 17:04 glibc-2.19\argp\argp-pv.c
文件 1405 2014-02-07 17:04 glibc-2.19\argp\argp-pvh.c
文件 5527 2014-02-07 17:04 glibc-2.19\argp\argp-test.c
文件 1373 2014-02-07 17:04 glibc-2.19\argp\argp-xinl.c
文件 26288 2014-02-07 17:04 glibc-2.19\argp\argp.h
文件 434 2014-02-07 17:04 glibc-2.19\argp\bug-argp1.c
文件 1048 2014-02-07 17:04 glibc-2.19\argp\bug-argp2.c
文件 1220 2014-02-07 17:04 glibc-2.19\argp\Makefile
文件 4360 2014-02-07 17:04 glibc-2.19\argp\tst-argp1.c
文件 2423 2014-02-07 17:04 glibc-2.19\argp\tst-argp2.c
文件 265 2014-02-07 17:04 glibc-2.19\argp\Versions
文件 1453 2014-02-07 17:04 glibc-2.19\assert\assert-perr.c
文件 2948 2014-02-07 17:04 glibc-2.19\assert\assert.c
文件 3571 2014-02-07 17:04 glibc-2.19\assert\assert.h
文件 21 2014-02-07 17:04 glibc-2.19\assert\Depend
文件 1024 2014-02-07 17:04 glibc-2.19\assert\Makefile
文件 1267 2014-02-07 17:04 glibc-2.19\assert\test-assert-perr.c
文件 1206 2014-02-07 17:04 glibc-2.19\assert\test-assert.c
............此处省略15275个文件信息
- 上一篇:BC45,BC++ 4.5 开发工具
- 下一篇:数字图像处理扑克牌识别程序
相关资源
- C++中头文件与源文件的作用详解
- 基于mfc的多线程文件传输
- C++多线程网络编程Socket
- VC++ 多线程文件读写操作
- C语言代码高亮html输出工具
- 猜数字游戏 c语言代码
- C语言课程设计
- 数字电位器C语言程序
- CCS FFT c语言算法
- 使用C语言编写的病房管理系统
- 通信过程中的RS编译码程序(c语言)
- 利用C++哈希表的方法实现电话号码查
- 计算机二级C语言上机填空,改错,编
- 用回溯法解决八皇后问题C语言实现
- 移木块游戏,可以自编自玩,vc6.0编写
- 简易教务管理系统c语言开发文档
- 操作系统课设 读写者问题 c语言实现
- 小波变换算法 c语言版
- C流程图生成器,用C语言代码 生成C语
- 3des加密算法C语言实现
- 简单的C语言点对点聊天程序
- 单片机c语言源程序(51定时器 八个按
- C++纯文字DOS超小RPG游戏
- 个人日常财务管理系统(C语言)
- MFC数字钟(基于VC6.0)
- c语言电子商务系统
- 小甲鱼C语言课件 源代码
- 将图片转换为C语言数组的程序
- 安科瑞智能电能表MODBUS通讯程序 VC6
- C语言实现的一个内存泄漏检测程序
评论
共有 条评论