mirror of
git://sourceware.org/git/newlib-cygwin.git
synced 2025-01-31 03:20:28 +08:00
* cygcheck.cc: Reformat.
This commit is contained in:
parent
b9262dd919
commit
b56dedef3e
@ -1,3 +1,7 @@
|
|||||||
|
2002-03-06 Christopher Faylor <cgf@redhat.com>
|
||||||
|
|
||||||
|
* cygcheck.cc: Reformat.
|
||||||
|
|
||||||
2002-03-06 Christopher Faylor <cgf@redhat.com>
|
2002-03-06 Christopher Faylor <cgf@redhat.com>
|
||||||
|
|
||||||
* cygcheck.cc (longopts): Use correct short option for --version.
|
* cygcheck.cc (longopts): Use correct short option for --version.
|
||||||
|
@ -65,8 +65,7 @@ struct
|
|||||||
const char *name;
|
const char *name;
|
||||||
int missing_is_good;
|
int missing_is_good;
|
||||||
}
|
}
|
||||||
static common_apps[] =
|
static common_apps[] = {
|
||||||
{
|
|
||||||
{"bash", 0},
|
{"bash", 0},
|
||||||
{"cat", 0},
|
{"cat", 0},
|
||||||
{"cpp", 1},
|
{"cpp", 1},
|
||||||
@ -382,7 +381,8 @@ cygwin_info (HANDLE h)
|
|||||||
int maj = atoi (dll_major);
|
int maj = atoi (dll_major);
|
||||||
dll_major[1] = c;
|
dll_major[1] = c;
|
||||||
int min = atoi (dll_major + 1);
|
int min = atoi (dll_major + 1);
|
||||||
sprintf (pbuf, "DLL version: %d.%d.%.*s", maj, min, len - 11, buf + 11);
|
sprintf (pbuf, "DLL version: %d.%d.%.*s", maj, min, len - 11,
|
||||||
|
buf + 11);
|
||||||
len = strlen (s = pbuf);
|
len = strlen (s = pbuf);
|
||||||
}
|
}
|
||||||
if (strncmp (s, "dll", 3) == 0)
|
if (strncmp (s, "dll", 3) == 0)
|
||||||
@ -417,8 +417,8 @@ dll_info (const char *path, HANDLE fh, int lvl, int recurse)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (SetFilePointer (fh, opthdr_ofs + 40, 0, FILE_BEGIN) == INVALID_SET_FILE_POINTER
|
if (SetFilePointer (fh, opthdr_ofs + 40, 0, FILE_BEGIN) ==
|
||||||
&& GetLastError () != NO_ERROR)
|
INVALID_SET_FILE_POINTER && GetLastError () != NO_ERROR)
|
||||||
keyeprint ("dll_info: SetFilePointer()");
|
keyeprint ("dll_info: SetFilePointer()");
|
||||||
|
|
||||||
if (!ReadFile (fh, &v, sizeof (v), &junk, 0))
|
if (!ReadFile (fh, &v, sizeof (v), &junk, 0))
|
||||||
@ -455,8 +455,8 @@ dll_info (const char *path, HANDLE fh, int lvl, int recurse)
|
|||||||
|
|
||||||
if (expbase)
|
if (expbase)
|
||||||
{
|
{
|
||||||
if (SetFilePointer (fh, expbase, 0, FILE_BEGIN) == INVALID_SET_FILE_POINTER
|
if (SetFilePointer (fh, expbase, 0, FILE_BEGIN) ==
|
||||||
&& GetLastError () != NO_ERROR)
|
INVALID_SET_FILE_POINTER && GetLastError () != NO_ERROR)
|
||||||
keyeprint ("dll_info: SetFilePointer()");
|
keyeprint ("dll_info: SetFilePointer()");
|
||||||
|
|
||||||
unsigned char *exp = (unsigned char *) malloc (expsz);
|
unsigned char *exp = (unsigned char *) malloc (expsz);
|
||||||
@ -486,8 +486,8 @@ dll_info (const char *path, HANDLE fh, int lvl, int recurse)
|
|||||||
int impbase = rva_to_offset (import_rva, sections, nsections, &impsz);
|
int impbase = rva_to_offset (import_rva, sections, nsections, &impsz);
|
||||||
if (impbase)
|
if (impbase)
|
||||||
{
|
{
|
||||||
if (SetFilePointer (fh, impbase, 0, FILE_BEGIN) == INVALID_SET_FILE_POINTER
|
if (SetFilePointer (fh, impbase, 0, FILE_BEGIN) ==
|
||||||
&& GetLastError () != NO_ERROR)
|
INVALID_SET_FILE_POINTER && GetLastError () != NO_ERROR)
|
||||||
keyeprint ("dll_info: SetFilePointer()");
|
keyeprint ("dll_info: SetFilePointer()");
|
||||||
|
|
||||||
unsigned char *imp = (unsigned char *) malloc (impsz);
|
unsigned char *imp = (unsigned char *) malloc (impsz);
|
||||||
@ -810,7 +810,8 @@ dump_sysinfo ()
|
|||||||
if (!more_info)
|
if (!more_info)
|
||||||
osname = (char *) "2000";
|
osname = (char *) "2000";
|
||||||
else if (osversionex.wProductType == VER_NT_SERVER
|
else if (osversionex.wProductType == VER_NT_SERVER
|
||||||
|| osversionex.wProductType == VER_NT_DOMAIN_CONTROLLER)
|
|| osversionex.wProductType ==
|
||||||
|
VER_NT_DOMAIN_CONTROLLER)
|
||||||
{
|
{
|
||||||
if (osversionex.wSuiteMask &VER_SUITE_DATACENTER)
|
if (osversionex.wSuiteMask &VER_SUITE_DATACENTER)
|
||||||
osname = (char *) "2000 Datacenter Server";
|
osname = (char *) "2000 Datacenter Server";
|
||||||
@ -827,7 +828,8 @@ dump_sysinfo ()
|
|||||||
if (!more_info)
|
if (!more_info)
|
||||||
osname = (char *) "XP";
|
osname = (char *) "XP";
|
||||||
else if (osversionex.wProductType == VER_NT_SERVER
|
else if (osversionex.wProductType == VER_NT_SERVER
|
||||||
|| osversionex.wProductType == VER_NT_DOMAIN_CONTROLLER)
|
|| osversionex.wProductType ==
|
||||||
|
VER_NT_DOMAIN_CONTROLLER)
|
||||||
{
|
{
|
||||||
if (osversionex.wSuiteMask & VER_SUITE_ENTERPRISE)
|
if (osversionex.wSuiteMask & VER_SUITE_ENTERPRISE)
|
||||||
osname = (char *) ".NET Enterprise Server";
|
osname = (char *) ".NET Enterprise Server";
|
||||||
@ -971,9 +973,9 @@ dump_sysinfo ()
|
|||||||
/* Report all errors, except if the Volume is ERROR_NOT_READY.
|
/* Report all errors, except if the Volume is ERROR_NOT_READY.
|
||||||
ERROR_NOT_READY is returned when removeable media drives are empty
|
ERROR_NOT_READY is returned when removeable media drives are empty
|
||||||
(CD, floppy, etc.) */
|
(CD, floppy, etc.) */
|
||||||
if (!GetVolumeInformation (drive, name, sizeof (name), &serno, &maxnamelen, &flags,
|
if (!GetVolumeInformation
|
||||||
fsname, sizeof (fsname))
|
(drive, name, sizeof (name), &serno, &maxnamelen, &flags, fsname,
|
||||||
&& GetLastError () != ERROR_NOT_READY)
|
sizeof (fsname)) && GetLastError () != ERROR_NOT_READY)
|
||||||
keyeprint ("dump_sysinfo: GetVolumeInformation()");
|
keyeprint ("dump_sysinfo: GetVolumeInformation()");
|
||||||
|
|
||||||
int dtype = GetDriveType (drive);
|
int dtype = GetDriveType (drive);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user