亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? filehdr.cc

?? nachos系統(tǒng)作業(yè) 實現(xiàn)線程系統(tǒng) 實現(xiàn)一個電梯模擬 附實驗報告
?? CC
字號:
// filehdr.cc //	Routines for managing the disk file header (in UNIX, this//	would be called the i-node).////	The file header is used to locate where on disk the //	file's data is stored.  We implement this as a fixed size//	table of pointers -- each entry in the table points to the //	disk sector containing that portion of the file data//	(in other words, there are no indirect or doubly indirect //	blocks). The table size is chosen so that the file header//	will be just big enough to fit in one disk sector, ////      Unlike in a real system, we do not keep track of file permissions, //	ownership, last modification date, etc., in the file header. ////	A file header can be initialized in two ways://	   for a new file, by modifying the in-memory data structure//	     to point to the newly allocated data blocks//	   for a file already on disk, by reading the file header from disk//// Copyright (c) 1992-1993 The Regents of the University of California.// All rights reserved.  See copyright.h for copyright notice and limitation // of liability and disclaimer of warranty provisions.#include "copyright.h"#include "system.h"#include "filehdr.h"//----------------------------------------------------------------------// FileHeader::Allocate// 	Initialize a fresh file header for a newly created file.//	Allocate data blocks for the file out of the map of free disk blocks.//	Return FALSE if there are not enough free blocks to accomodate//	the new file.////	"freeMap" is the bit map of free disk sectors//	"fileSize" is the bit map of free disk sectors//----------------------------------------------------------------------boolFileHeader::Allocate(BitMap *freeMap, int fileSize){     numBytes = fileSize;    numSectors  = divRoundUp(fileSize, SectorSize);    if (freeMap->NumClear() < numSectors)	return FALSE;		// not enough space    for (int i = 0; i < numSectors; i++)	dataSectors[i] = freeMap->Find();    return TRUE;}//----------------------------------------------------------------------// FileHeader::Deallocate// 	De-allocate all the space allocated for data blocks for this file.////	"freeMap" is the bit map of free disk sectors//----------------------------------------------------------------------void FileHeader::Deallocate(BitMap *freeMap){    for (int i = 0; i < numSectors; i++) {	ASSERT(freeMap->Test((int) dataSectors[i]));  // ought to be marked!	freeMap->Clear((int) dataSectors[i]);    }}//----------------------------------------------------------------------// FileHeader::FetchFrom// 	Fetch contents of file header from disk. ////	"sector" is the disk sector containing the file header//----------------------------------------------------------------------voidFileHeader::FetchFrom(int sector){    synchDisk->ReadSector(sector, (char *)this);}//----------------------------------------------------------------------// FileHeader::WriteBack// 	Write the modified contents of the file header back to disk. ////	"sector" is the disk sector to contain the file header//----------------------------------------------------------------------voidFileHeader::WriteBack(int sector){    synchDisk->WriteSector(sector, (char *)this); }//----------------------------------------------------------------------// FileHeader::ByteToSector// 	Return which disk sector is storing a particular byte within the file.//      This is essentially a translation from a virtual address (the//	offset in the file) to a physical address (the sector where the//	data at the offset is stored).////	"offset" is the location within the file of the byte in question//----------------------------------------------------------------------intFileHeader::ByteToSector(int offset){    return(dataSectors[offset / SectorSize]);}//----------------------------------------------------------------------// FileHeader::FileLength// 	Return the number of bytes in the file.//----------------------------------------------------------------------intFileHeader::FileLength(){    return numBytes;}//----------------------------------------------------------------------// FileHeader::Print// 	Print the contents of the file header, and the contents of all//	the data blocks pointed to by the file header.//----------------------------------------------------------------------voidFileHeader::Print(){    int i, j, k;    char *data = new char[SectorSize];    printf("FileHeader contents.  File size: %d.  File blocks:\n", numBytes);    for (i = 0; i < numSectors; i++)	printf("%d ", dataSectors[i]);    printf("\nFile contents:\n");    for (i = k = 0; i < numSectors; i++) {	synchDisk->ReadSector(dataSectors[i], data);        for (j = 0; (j < SectorSize) && (k < numBytes); j++, k++) {	    if ('\040' <= data[j] && data[j] <= '\176')   // isprint(data[j])		printf("%c", data[j]);            else		printf("\\%x", (unsigned char)data[j]);	}        printf("\n");     }    delete [] data;}

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美一区二区三区免费在线看| 久久亚洲影视婷婷| 欧美一区二区在线观看| 91国产免费看| 欧美精品自拍偷拍动漫精品| 91麻豆精品国产91久久久更新时间 | 国产福利91精品一区| 日韩av一区二区三区四区| 亚洲最新视频在线观看| 午夜成人免费电影| 国产综合色在线视频区| 丁香网亚洲国际| 色婷婷精品久久二区二区蜜臀av| 欧美精品v日韩精品v韩国精品v| 日韩欧美亚洲一区二区| 国产精品久久久久婷婷| 天堂午夜影视日韩欧美一区二区| 久久99热狠狠色一区二区| 成人性生交大合| 色婷婷激情一区二区三区| 欧美老年两性高潮| 亚洲精品欧美综合四区| 中文字幕日韩一区| 精品久久久久久久一区二区蜜臀| 在线精品视频一区二区三四| 26uuu久久综合| 亚洲国产成人va在线观看天堂| 99国产一区二区三精品乱码| 欧美色视频在线| 亚洲久草在线视频| 亚洲欧美在线观看| 六月丁香综合在线视频| 99久久精品免费看| 中文字幕乱码一区二区免费| 美女诱惑一区二区| 欧美激情一区二区三区蜜桃视频 | 国产一区二区女| 精品国产乱码久久久久久影片| 精品一区二区三区免费| 国产欧美日产一区| 色老汉一区二区三区| 偷拍亚洲欧洲综合| 精品国一区二区三区| 成人三级伦理片| 天天做天天摸天天爽国产一区| 欧美三级一区二区| 一区二区成人在线| 91色视频在线| 亚洲国产成人私人影院tom| 日本在线不卡视频| 精品国产成人在线影院| 麻豆视频一区二区| 久久品道一品道久久精品| 亚洲无人区一区| 97久久超碰国产精品电影| 久久久久久久久99精品| 亚洲成人免费看| 一本一道综合狠狠老| 日本一区二区三区电影| 久久精品国产在热久久| 欧美狂野另类xxxxoooo| 亚洲一区二区三区四区中文字幕 | 欧美成人猛片aaaaaaa| 国产日产亚洲精品系列| 国内精品写真在线观看| 日韩欧美在线网站| 日本不卡在线视频| 这里只有精品99re| 亚洲成人7777| 欧美亚洲高清一区| 一区二区三区在线视频观看| www.成人在线| 日本一区二区三区视频视频| 国产美女一区二区三区| 26uuuu精品一区二区| 久久成人免费网| 精品福利av导航| 蜜臀av国产精品久久久久| 日韩欧美在线网站| 久草热8精品视频在线观看| 日韩欧美精品在线| 热久久免费视频| 日韩欧美国产三级电影视频| 久草在线在线精品观看| 久久精品夜色噜噜亚洲aⅴ| 国产精品1区2区| 国产精品三级av在线播放| 成人av集中营| ...xxx性欧美| 日本精品一级二级| 亚洲卡通欧美制服中文| 欧美日韩国产欧美日美国产精品| 日韩在线a电影| 欧美tickling网站挠脚心| 国产精品一二二区| 中文字幕在线一区免费| 色婷婷一区二区| 视频在线观看一区二区三区| 欧美mv和日韩mv国产网站| 国产精品一区二区黑丝| 国产精品久久久久久福利一牛影视 | 91丨九色丨国产丨porny| 亚洲精品一二三四区| 欧美在线影院一区二区| 视频一区在线视频| 久久只精品国产| 99热在这里有精品免费| 亚洲国产你懂的| 精品美女在线观看| av综合在线播放| 亚洲第一二三四区| 精品国产一区二区三区av性色| 国产福利一区二区三区| 亚洲视频在线一区观看| 777午夜精品视频在线播放| 国产在线不卡一卡二卡三卡四卡| 国产精品色眯眯| 在线电影国产精品| 国产精品一区专区| 亚洲综合久久av| 日韩精品一区二区三区在线| 国产v综合v亚洲欧| 一区2区3区在线看| 日韩亚洲电影在线| 成人av网站在线| 日本在线观看不卡视频| 国产精品久久久久毛片软件| 欧美老女人第四色| 成人激情小说网站| 图片区日韩欧美亚洲| 国产精品丝袜久久久久久app| 欧洲精品中文字幕| 国产乱色国产精品免费视频| 亚洲女爱视频在线| 欧美精品一区二区三区在线播放 | 午夜成人在线视频| 欧美激情一区二区三区蜜桃视频| 欧美久久久一区| 国产很黄免费观看久久| 亚洲国产毛片aaaaa无费看| 国产无一区二区| 这里只有精品免费| 色综合天天综合色综合av| 韩国精品主播一区二区在线观看 | 欧美日韩五月天| 国产成人在线免费| 美女精品自拍一二三四| 一区二区三区小说| 国产欧美一区二区三区网站| 欧美日韩国产另类不卡| 成人动漫av在线| 精品一区二区av| 亚洲国产精品麻豆| 中文字幕视频一区二区三区久| 日韩女优电影在线观看| 欧美视频一区二区三区四区| 成人在线视频首页| 精品影视av免费| 日韩精品一二三区| 一区av在线播放| 国产精品第13页| 久久久99免费| 日韩欧美中文字幕一区| 欧美高清激情brazzers| 欧美在线不卡视频| 91麻豆精品一区二区三区| 国产一二三精品| 蓝色福利精品导航| 日韩国产在线一| 亚洲一二三四久久| 亚洲男人的天堂在线aⅴ视频| 国产日韩欧美高清| 精品免费一区二区三区| 日韩欧美一区二区视频| 欧美女孩性生活视频| 欧美影院一区二区| 色香蕉久久蜜桃| 99精品欧美一区二区三区综合在线| 国产.欧美.日韩| 国产一区美女在线| 国产一区三区三区| 国产精品77777| 国产成人精品免费| 国产成人免费网站| 国产成人精品aa毛片| 顶级嫩模精品视频在线看| 岛国精品在线观看| 成人美女视频在线观看| 成人影视亚洲图片在线| 成人激情文学综合网| 99久久精品国产网站| 9久草视频在线视频精品| 不卡av在线免费观看| 99久久国产综合精品色伊| 国产精品资源在线观看| 国产69精品久久久久毛片| 不卡视频一二三| 色噜噜狠狠成人网p站| 欧美日韩另类一区| 91精品综合久久久久久|