Rename to dsk2dc42

This commit is contained in:
Christopher Kobayashi 2020-04-21 20:52:18 +09:00
parent f0251657eb
commit 3a86d2170b
2 changed files with 6 additions and 6 deletions

View File

@ -1,10 +1,10 @@
CFLAGS= -O2 -Wall -Werror -ggdb
all: dc42cksm makedc42
all: dc42cksm dsk2dc42
install: all
install -m755 dc42cksm makedc42 /usr/local/bin/
install -m755 dc42cksm dsk2dc42 /usr/local/bin/
clean:
rm -f dc42cksm makedc42 *.o
rm -f dc42cksm dsk2dc42 *.o

View File

@ -53,8 +53,6 @@ int main(int argc, char **argv)
printf("%s: could not stat\n", argv[1]);
}
printf("%s: size is %li\n", argv[1], inputfile_stat.st_size);
file_buffer = calloc(1, inputfile_stat.st_size);
if (!file_buffer) {
printf("%s: could not allocate buffer\n", argv[1]);
@ -62,7 +60,7 @@ int main(int argc, char **argv)
return -1;
}
printf("%s: read %li bytes into buffer\n", argv[1],
printf("%s: size %li bytes\n", argv[1],
fread(file_buffer, 1, inputfile_stat.st_size, inputfile));
fclose(inputfile);
@ -126,6 +124,8 @@ int main(int argc, char **argv)
fwrite(&header, sizeof(header), 1, outputfile);
fwrite(file_buffer, inputfile_stat.st_size, 1, outputfile);
printf("%s: ensure \"%s\" type/creator is dImg/dCpy\n", argv[1], outputfilename);
if (file_buffer != NULL)
free(file_buffer);