turn on command options

svn path=/trunk/; revision=16885
This commit is contained in:
Steven Edwards 2005-07-29 23:01:16 +00:00
parent 42f41fa7c2
commit 4214fc67a7
2 changed files with 5 additions and 12 deletions

View file

@ -1,5 +1,5 @@
CC=mingw32-gcc
OBJECTS = boot.o check.o common.o dosfsck.o fat.o file.o io.o lfn.o
OBJECTS = getopt.o boot.o check.o common.o dosfsck.o fat.o file.o io.o lfn.o
all: dosfsck.exe

View file

@ -12,8 +12,8 @@
#include <stdlib.h>
#include <string.h>
#include <stdlib.h>
//#include <unistd.h>
//#include <getopt.h>
#include <unistd.h>
#include <getopt.h>
#include "common.h"
#include "dosfsck.h"
@ -81,8 +81,7 @@ static void check_atari( void )
int main(int argc,char **argv)
{
int optind;
{
DOS_FS fs;
int rw,salvage_files,verify,c;
unsigned long free_clusters;
@ -90,12 +89,7 @@ int main(int argc,char **argv)
rw = salvage_files = verify = 0;
interactive = 1;
check_atari();
#if 1
optind = 1;
verbose = 1;
list = 1;
#else
while ((c = getopt(argc,argv,"Aad:flnrtu:vVwy")) != EOF)
switch (c) {
case 'A': /* toggle Atari format */
@ -149,7 +143,6 @@ int main(int argc,char **argv)
exit(2);
}
if (optind != argc-1) usage(argv[0]);
#endif
printf( "dosfsck " VERSION ", " VERSION_DATE ", FAT32, LFN\n" );
fs_open(argv[optind],rw);