📄 1.c
字号:
#include <stdlib.h>
#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <dirent.h>
int main()
{
DIR * dp = NULL;
struct dirent * entry = NULL;
char * fifo_name;
dp = opendir("/tmp");
while((entry = readdir(dp))!=NULL)
{
if(strncmp(entry->d_name,"my_fifo_",8)==0)
{
fifo_name = entry->d_name+8;
printf("%s\n",fifo_name);
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -