mirror of
https://github.com/aaru-dps/fstester.git
synced 2025-12-16 19:24:39 +00:00
Remove some unused code.
This commit is contained in:
@@ -74,15 +74,12 @@ void GetOsInfo()
|
|||||||
case DOS_FLAVOR_WINME:
|
case DOS_FLAVOR_WINME:
|
||||||
printf("Will not run under Windows 9x. Exiting...\n");
|
printf("Will not run under Windows 9x. Exiting...\n");
|
||||||
exit(1);
|
exit(1);
|
||||||
break;
|
|
||||||
case DOS_FLAVOR_WINNT:
|
case DOS_FLAVOR_WINNT:
|
||||||
printf("Will not run under Windows NT. Exiting...\n");
|
printf("Will not run under Windows NT. Exiting...\n");
|
||||||
exit(1);
|
exit(1);
|
||||||
break;
|
|
||||||
case DOS_FLAVOR_OS2:
|
case DOS_FLAVOR_OS2:
|
||||||
printf("Will not run under OS/2. Exiting...\n");
|
printf("Will not run under OS/2. Exiting...\n");
|
||||||
exit(1);
|
exit(1);
|
||||||
break;
|
|
||||||
case DOS_FLAVOR_PTSDOS:
|
case DOS_FLAVOR_PTSDOS:
|
||||||
printf("OS information:\n");
|
printf("OS information:\n");
|
||||||
printf("\tRunning under PTS-DOS %d.%d\n", dosuname_version.major, dosuname_version.minor);
|
printf("\tRunning under PTS-DOS %d.%d\n", dosuname_version.major, dosuname_version.minor);
|
||||||
|
|||||||
@@ -49,10 +49,9 @@ void Filenames(const char* path)
|
|||||||
int16_t refNum;
|
int16_t refNum;
|
||||||
int16_t refFile;
|
int16_t refFile;
|
||||||
int32_t dirId;
|
int32_t dirId;
|
||||||
FInfo finderInfo;
|
|
||||||
int32_t count;
|
int32_t count;
|
||||||
char message[300];
|
char message[300];
|
||||||
int pos = 0;
|
int pos;
|
||||||
HParamBlockRec dirPB;
|
HParamBlockRec dirPB;
|
||||||
|
|
||||||
snprintf((char*)str255, 255, "%s", path);
|
snprintf((char*)str255, 255, "%s", path);
|
||||||
|
|||||||
@@ -43,16 +43,13 @@ Copyright (C) 2011-2021 Natalia Portillo
|
|||||||
|
|
||||||
void MillionFiles(const char* path)
|
void MillionFiles(const char* path)
|
||||||
{
|
{
|
||||||
OSErr rc, wRc, cRc;
|
OSErr rc;
|
||||||
Str255 str255;
|
Str255 str255;
|
||||||
HVolumeParam hpb;
|
HVolumeParam hpb;
|
||||||
int16_t refNum;
|
int16_t refNum;
|
||||||
int16_t refFile;
|
|
||||||
int32_t dirId;
|
int32_t dirId;
|
||||||
FInfo finderInfo;
|
|
||||||
int32_t count;
|
|
||||||
char filename[9];
|
char filename[9];
|
||||||
int pos = 0;
|
int pos;
|
||||||
HParamBlockRec dirPB;
|
HParamBlockRec dirPB;
|
||||||
|
|
||||||
snprintf((char*)str255, 255, "%s", path);
|
snprintf((char*)str255, 255, "%s", path);
|
||||||
|
|||||||
@@ -27,17 +27,7 @@ Contains 32-bit OS/2 code
|
|||||||
Copyright (C) 2011-2021 Natalia Portillo
|
Copyright (C) 2011-2021 Natalia Portillo
|
||||||
*****************************************************************************/
|
*****************************************************************************/
|
||||||
|
|
||||||
#define INCL_DOSMISC
|
#include "../../include/defs.h"
|
||||||
#define INCL_DOSFILEMGR
|
|
||||||
|
|
||||||
#include <os2.h>
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
#include <string.h>
|
|
||||||
|
|
||||||
#include "../os2.h"
|
|
||||||
#include "include/consts.h"
|
|
||||||
#include "include/defs.h"
|
|
||||||
|
|
||||||
void ExtendedAttributes(const char* path)
|
void ExtendedAttributes(const char* path)
|
||||||
{ /* TODO: Implement */
|
{ /* TODO: Implement */
|
||||||
|
|||||||
@@ -86,7 +86,7 @@ Copyright (C) 2011-2021 Natalia Portillo
|
|||||||
|
|
||||||
#define __os2_chdir(path) DosSetCurrentDir(path)
|
#define __os2_chdir(path) DosSetCurrentDir(path)
|
||||||
#define __os2_mkdir(path) DosCreateDir(path, NULL)
|
#define __os2_mkdir(path) DosCreateDir(path, NULL)
|
||||||
#define __os2_delete(path) DosDelete(path);
|
#define __os2_delete(path) DosDelete(path)
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ Copyright (C) 2011-2021 Natalia Portillo
|
|||||||
void DeleteFiles(const char* path)
|
void DeleteFiles(const char* path)
|
||||||
{
|
{
|
||||||
char filename[9];
|
char filename[9];
|
||||||
long pos = 0;
|
long pos;
|
||||||
FILE* h;
|
FILE* h;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ void Filenames(const char* path)
|
|||||||
FILE* h;
|
FILE* h;
|
||||||
int rc, wRc, cRc;
|
int rc, wRc, cRc;
|
||||||
char message[300];
|
char message[300];
|
||||||
int pos = 0;
|
int pos;
|
||||||
|
|
||||||
ret = chdir(path);
|
ret = chdir(path);
|
||||||
|
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ Copyright (C) 2011-2021 Natalia Portillo
|
|||||||
void DeleteFiles(const char* path)
|
void DeleteFiles(const char* path)
|
||||||
{
|
{
|
||||||
char filename[9];
|
char filename[9];
|
||||||
DWORD pos = 0;
|
DWORD pos;
|
||||||
HANDLE h;
|
HANDLE h;
|
||||||
BOOL ret;
|
BOOL ret;
|
||||||
DWORD error;
|
DWORD error;
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ void Filenames(const char* path)
|
|||||||
DWORD dwNumberOfBytesWritten;
|
DWORD dwNumberOfBytesWritten;
|
||||||
DWORD rc, wRc, cRc;
|
DWORD rc, wRc, cRc;
|
||||||
char message[300];
|
char message[300];
|
||||||
int pos = 0;
|
int pos;
|
||||||
|
|
||||||
lpRootPathName = malloc(dwMaxNameSize);
|
lpRootPathName = malloc(dwMaxNameSize);
|
||||||
|
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ Copyright (C) 2011-2021 Natalia Portillo
|
|||||||
void MillionFiles(const char* path)
|
void MillionFiles(const char* path)
|
||||||
{
|
{
|
||||||
char filename[9];
|
char filename[9];
|
||||||
DWORD pos = 0;
|
DWORD pos;
|
||||||
HANDLE h;
|
HANDLE h;
|
||||||
BOOL ret;
|
BOOL ret;
|
||||||
DWORD error;
|
DWORD error;
|
||||||
|
|||||||
@@ -55,7 +55,7 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
LPSTR lpRootPathName;
|
LPSTR lpRootPathName;
|
||||||
const size_t pathSize = strlen(path);
|
const size_t pathSize = strlen(path);
|
||||||
HANDLE h;
|
HANDLE h;
|
||||||
DWORD rc, wRc, cRc, tRc;
|
DWORD rc, wRc, cRc;
|
||||||
DWORD dwNumberOfBytesWritten;
|
DWORD dwNumberOfBytesWritten;
|
||||||
|
|
||||||
lpRootPathName = malloc(dwMaxNameSize);
|
lpRootPathName = malloc(dwMaxNameSize);
|
||||||
@@ -102,7 +102,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -125,7 +124,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -149,7 +147,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -172,7 +169,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -200,7 +196,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -228,7 +223,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -251,7 +245,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -274,7 +267,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -301,7 +293,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -336,7 +327,6 @@ void Fragmentation(const char* path, size_t clusterSize)
|
|||||||
rc = 0;
|
rc = 0;
|
||||||
wRc = 0;
|
wRc = 0;
|
||||||
cRc = 0;
|
cRc = 0;
|
||||||
tRc = 0;
|
|
||||||
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
if(h == INVALID_HANDLE_VALUE) rc = GetLastError();
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -29,7 +29,6 @@ Copyright (C) 2011-2021 Natalia Portillo
|
|||||||
|
|
||||||
// ReSharper disable CppJoinDeclarationAndAssignment
|
// ReSharper disable CppJoinDeclarationAndAssignment
|
||||||
// ReSharper disable CppDeprecatedEntity
|
// ReSharper disable CppDeprecatedEntity
|
||||||
#define _CRT_SECURE_NO_WARNINGS 1
|
|
||||||
|
|
||||||
#include "../include/defs.h"
|
#include "../include/defs.h"
|
||||||
|
|
||||||
|
|||||||
@@ -163,9 +163,6 @@ void ExtendedAttributes(const char* path)
|
|||||||
|
|
||||||
printf("Creating files with extended attributes.\n");
|
printf("Creating files with extended attributes.\n");
|
||||||
|
|
||||||
rc = 0;
|
|
||||||
wRc = 0;
|
|
||||||
cRc = 0;
|
|
||||||
rRc = 0;
|
rRc = 0;
|
||||||
cmp = TRUE;
|
cmp = TRUE;
|
||||||
h = CreateFileA("COMMENTS",
|
h = CreateFileA("COMMENTS",
|
||||||
@@ -225,9 +222,6 @@ void ExtendedAttributes(const char* path)
|
|||||||
rRc,
|
rRc,
|
||||||
cmp);
|
cmp);
|
||||||
|
|
||||||
rc = 0;
|
|
||||||
wRc = 0;
|
|
||||||
cRc = 0;
|
|
||||||
rRc = 0;
|
rRc = 0;
|
||||||
cmp = TRUE;
|
cmp = TRUE;
|
||||||
h = CreateFileA("COMMENTS.CRT",
|
h = CreateFileA("COMMENTS.CRT",
|
||||||
@@ -287,9 +281,6 @@ void ExtendedAttributes(const char* path)
|
|||||||
rRc,
|
rRc,
|
||||||
cmp);
|
cmp);
|
||||||
|
|
||||||
rc = 0;
|
|
||||||
wRc = 0;
|
|
||||||
cRc = 0;
|
|
||||||
rRc = 0;
|
rRc = 0;
|
||||||
cmp = TRUE;
|
cmp = TRUE;
|
||||||
h = CreateFileA("ICON",
|
h = CreateFileA("ICON",
|
||||||
|
|||||||
Reference in New Issue
Block a user