![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Linux
文章平均质量分 66
csghydiaoke
这个作者很懒,什么都没留下…
展开
-
Linux系统调用 file-cp.c
/*Using system call implementation file copy function: Manual input source file target file pathname pathname If the destination does not exist, create and write*/ #include #include #include #原创 2012-12-25 11:30:03 · 737 阅读 · 0 评论 -
linux下错误的捕获:errno和strerror的使用
经常在调用linux 系统api 的时候会出现一些错误,比方说使用open() write() creat()之类的函数有些时候会返回-1,也就是调用失败,这个时候往往需要知道失败的原因。这个时候使用errno这个全局变量就相当有用了。 在程序代码中包含 #include ,然后每次程序调用失败的时候,系统会自动用用错误代码填充errno这个全局变量,这样你只需要读errno这个全局变量原创 2012-12-29 11:32:01 · 453 阅读 · 0 评论 -
#include <sys/stat.h>文件状态
#include 文件状态, 是unix/linux系统定义文件状态所在的伪标准头文件。 含有类型与函数: dev_t st_dev Device ID of device containing file. ino_t st_ino File serial number.原创 2012-12-29 10:29:37 · 1598 阅读 · 0 评论 -
#include <sys/types.h>的作用
#include 基本系统数据类型 是Unix/Linux系统的基本系统数据类型的头文件,含有size_t,time_t,pid_t等类型。 NAME sys/types.h - data types SYNOPSIS #include DESCRIPTION The header shall include de原创 2012-12-29 10:28:04 · 15606 阅读 · 0 评论 -
20121230 linux进阶者公开课之”如何学好linux“
原创 2012-12-30 22:15:39 · 333 阅读 · 0 评论