-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpfe.c
46 lines (39 loc) · 913 Bytes
/
pfe.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*
*Author: Stephen Brikiatis, Kelly Morrissey
*Class: CSI-385-01
*Assignment: FAT 12
*Date Assigned: 08/30/16
*Due Date: 11/02/16
*
* Description: This code locates FAT entries and prints them out to the user
*
* Certification of Authenticity: I certify that this assignment is entirely my own work.
*/
#include <stdio.h>
#include <stdlib.h>
extern get_fat_entry(int fat_entry_number, unsigned char* fat);
FILE* FILE_SYSTEM_ID;
int BYTES_PER_SECTOR;
int main(int argc, char *argv[])
{
if(argc > 3)
{
printf("Too many items.");
exit(-1);
}
else if(argc < 3)
{
printf("Too few items.");
exit(-1);
}
if(argv[2] > argv[3])
{
printf("The first entry cannot be smaller than the second.");
exit(-1);
}
else if(argv[2] < 2)
{
printf("Cannot access this entry.");
}
return 0;
}