minor update.

svn path=/trunk/; revision=4076
This commit is contained in:
Robert Dickenson 2003-01-27 15:12:12 +00:00
parent 6c08d81780
commit 9cac22fb79

View file

@ -86,7 +86,9 @@ static BOOL test_file_truncate(TCHAR* file_name)
TCHAR* file_data = _T("this file should have been truncated to zero bytes...");
FILE *file = _tfopen(file_name, _T("wb"));
if (verbose_flagged) {
_tprintf(_T("test_file_truncate(\"%s\")\n"), file_name);
}
if (file != NULL) {
if (_fputts(file_data, file) != _TEOF) {
@ -115,7 +117,9 @@ static BOOL test_file_truncate(TCHAR* file_name)
if (file != NULL) {
count = 0;
while ((ch = _fgettc(file)) != _TEOF) {
if (verbose_flagged) {
_tprintf(_THEX_FORMAT, ch);
}
++count;
}
error_code = ferror(file);
@ -380,6 +384,7 @@ static int test_files(int test_num, char* type)
if (test_file_truncate(_T("zerosize.foo"))) {
printf("System unable to truncate files yet, unlinking:\n");
test_unlink_files();
}