Commit Graph

22 Commits

Author SHA1 Message Date
Corinna Vinschen 822b654fe0 * dump_setup.cc (tfx_chars): New WCHAR array, copied from Cygwin.
(transform_chars): New function, copied from Cygwin.
	(simple_nt_stat): New function to check file existance using native
	NT function.  Explain why.
	(directory_exists): Call simple_nt_stat.
	(file_exists): Ditto.
2010-07-21 10:30:53 +00:00
Corinna Vinschen 96f1582977 * dump_setup.cc (dump_file): Read requested content from setup.rc
file created by newer setup.exe.
2010-07-05 12:28:48 +00:00
Christopher Faylor a35d9f1a67 * cygcheck.cc (pathlike::check_existence): Remove class name from declaration.
(display_internet_error): Use proper format specifier for DWORD.
(environ): Remove unneeded declaration.
(main): Use brace around nested if to avoid an overly-helpful compiler warning.
* dump_setup.cc (parse_filename): Reorganize nested if to avoid an
overly-helpful compiler warning.
* path.cc (GUID_shortcut): Use braces around part of initializer which needs
them.
(conv_fstab_spaces): Parenthesize assignment in while loop to avoid a compiler
warning.
(struct opt): Make static.
* ps.cc (main): Reorganize nested if to avoid an overly-helpful compiler
warning.
* regtool.cc: Make some anonymous structs static to avoid a compiler warning.
* ssp.c (lookup_thread_id): Initialize *tix to zero to avoid potential
uninitialized use.
* strace.cc (add_child): Use proper format specifier for DWORD.
(remove_child): Ditto.
(proc_child): Ditto.
2008-09-12 22:43:10 +00:00
Christopher Faylor 25687b0f76 * cygcheck.cc (nuke): Use malloc rather than alloca for environment variables.
(load_cygwin): Ditto.
* dump_setup.cc (parse_filename): Cosmetic changes.
(get_packages): Ditto.
2008-08-27 20:11:11 +00:00
Corinna Vinschen 14df41c155 * dump_setup.cc (package_find): Fix is_alias computation for "/usr/lib". 2005-12-19 16:58:33 +00:00
Christopher Faylor 4bfc614b42 fix whitespace, update some copyrights 2004-10-25 15:49:36 +00:00
Corinna Vinschen 79de498006 * dump_setup.cc (dump_setup): Remove unneeded strlen when check_files
is not set.
2004-09-23 10:32:20 +00:00
Corinna Vinschen 71de401447 * dump_setup.cc (dump_setup): Avoid trailing spaces on package-list. 2004-09-22 11:50:51 +00:00
Christopher Faylor d31c5928dd * Makefile.in: Detect existence of mingw zlib headers and libraries. Build
cygcheck wihtout package checking if they are unavailable.
* dump_setup.cc: Generate dummy zlib macros when zlib is not available.
(open_package_list): Use zlib functions to uncompress package lists.  Return
gzFile rather than FILE *.
(check_package_files): Change fp to gzFile to accommodate zlib functions.  Use
gzgets to read from package file.  Use gzclose to close the handle.
(package_list): Ditto.
(package_find): Ditto.
2003-09-08 02:50:02 +00:00
Christopher Faylor 1f602fd729 * dump_setup.cc (check_package_files): Don't fail on empty package. 2003-09-06 02:02:30 +00:00
Corinna Vinschen 919497ee6b * dump_setup.cc (check_package_files): Strip leading / and ./ from
package file names.
2003-08-17 17:26:08 +00:00
Corinna Vinschen b723879025 * dump_setup.cc (package_find): Don't stop searching on missing
file list.
	(package_list): Ditto.

	* dump_setup.cc: (package_list): Make output terse unless
	verbose requested.  Fix formatting.
	(package_find): Ditto.
2003-08-16 09:09:09 +00:00
Corinna Vinschen 200f243c42 * cygcheck.cc (main): Fix some formatting and help text printing.
* cygcheck.cc (find_package,list_package): New global
	variables.
	(usage): Add "--find-package" and "--list-package" options,
	reformat output.
	(longopts, opts): Add "--find-package" and "--list-package"
	options.
	(main): Process the "--find-package" and "--list-package"
	flags.  Add new semantic checks.  Add calls to find_package()
	and list_package().
	* dump_setup.cc: Fix header comment.
	(match_argv): Change return type to int to distinguish
	between real matches and default ones.
	(open_package_list): New static function.
	(check_package_files): Factor out opening the package list
	file into open_package_list().
	(get_packages): New static function.
	(dump_setup): Factor out getting a list of packages into
	get_packages().
	(package_list, package_find): New global functions.
2003-08-15 20:26:11 +00:00
Corinna Vinschen e2b1a74c13 * dump_setup.cc (check_package_files): Fix extra '/' in filename.
Resize command buffer.  Fix buffer overflow bug.
2003-08-13 19:37:40 +00:00
Christopher Faylor e41630b08a * dump_setup.cc (dump_setup): Check for the existence of the package list file.
Rework slightly to use static buffer for popen commands.
2003-08-10 01:07:04 +00:00
Christopher Faylor 58d4b72d33 * dump_setup.cc (version_len): New static variable.
(could_not_access,directory_exists): New static function.
(file_exists): Ditto.
(check_package_files): Ditto.
(dump_setup): Check the contents of each package if check_files is true and
output the result in the "Status" column.  Flush output after each package.
* dump_setup.cc (dump_setup): Remove redundant null check.  Add informative
message if package info not found.
2003-08-09 16:32:22 +00:00
Christopher Faylor 3202ad2b9e * dump_setup.cc (compar): Use case insensitive comparisons.
(dump_setup): Calculate package_len based on already used "len".  Don't bother
with version_len.
2003-02-07 21:34:34 +00:00
Corinna Vinschen eceb45bdff * dump_setup.cc (dump_setup): Compute the longest package name
and align columns properly.
2003-02-07 21:11:44 +00:00
Christopher Faylor 1c2b9fe563 * dump_setup.cc (parse_filename): Don't consider '_' part of the version. 2002-01-29 18:37:00 +00:00
Christopher Faylor 71f90de808 * cygcheck.cc (scan_registry): Open registry with read-only access.
(main): Reflect argument change for dump_setup.
* dump_setup.cc (dump_setup): Add preliminary extra argument for future use.
* path.cc (read_mounts): Open registry with read-only access.
2001-11-12 00:14:27 +00:00
Christopher Faylor da9e28d0fa * cygcheck.cc (main): Display package info when '-s' is specified.
* dump_setup.cc (dump_setup): Change header.  Remove typo.  Always sort
packages output.
2001-11-11 06:16:18 +00:00
Christopher Faylor d0d517913c * dump_setup.cc: New file.
* Makefile.in: Add info for dump_setup.o.
* cygcheck.cc (main): Recognize '-c' option for checking setup installed base.
* path.cc (cygpath): Read mount table if not loaded.
2001-11-11 06:07:36 +00:00