?? halt.c
字號:
#include <stdio.h>
#include "filesys.h"
halt()
{
struct inode *inode;
chdir("..");
iput(cur_path_inode);
for(i=0;i<USERNUM;i++)
{
if(user[i].u_uid!=0)
{
for(j=0;j<NOFILE;i++)
{
if(user[i].u_ofile[j]!=SYSOPENFILE+1)
{
close(user[i].u_ofile[j]);
user[i].u_ofile[j]=SYSOPENFILE+1;
}
}
}
}
fseek(fd,BLOCKSIZ,SEEK_SET);
fwrite(&filsys,1,sizeof(struct filsys),fd);
fclose(fd);
printf("\nGood Bye\n\n");
printf("\npress any key to continue...\n\n");
getchar();
exit(0);
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -