Commit Graph

6003 Commits

Author SHA1 Message Date
Christopher Faylor 4effb32b81 * select.cc (select_stuff::test_and_set): Remove workaround and use proper
constructor.
2012-12-18 17:32:45 +00:00
Christopher Faylor 9574be60a7 * select.cc (select_stuff::test_and_set): Work around problem of new() not
returning zeroed memory.
2012-12-18 16:41:38 +00:00
Corinna Vinschen 05297cca5f * fhandler.cc (fhandler_base::write): Don't attempt to sparsify
an already sparse file.  Drop check for FILE_SUPPORTS_SPARSE_FILES
	flag.  Explicitely set FILE_ATTRIBUTE_SPARSE_FILE attribute in
	cached attributes.
	(fhandler_base::lseek): Only set did_lseek if sparseness is supported.
	* fhandler_disk_file.cc (fhandler_disk_file::ftruncate): Don't attempt
	to sparsify an already sparse file.  Explicitely set
	FILE_ATTRIBUTE_SPARSE_FILE attribute in cached attributes.
	* mount.cc (oopt): Add "sparse" flag.
	(fillout_mntent): Ditto.
	* path.h (enum path_types): Add PATH_SPARSE.
	(path_conv::support_sparse): New method.
	(path_conv::fs_flags): Constify.
	(path_conv::fs_name_len): Ditto.
	include/sys/mount.h: Replace unused MOUNT_MIXED flag with MOUNT_SPARSE.
2012-12-14 10:45:29 +00:00
Christopher Faylor 8cabc308a2 * sigproc.h (sig_send): Accept tid as argument #3. Default to NULL.
* sigproc.cc (sig_send): Ditto.  Pass tid to other sig_send.
(sigpending): Send current thread as arg #3.
2012-12-10 22:13:26 +00:00
Christopher Faylor ff8ba3cabe * exceptions.cc (sigpacket::process): Reorganize to avoid use of tls before
initialization.
* fhandler_fifo.cc (fhandler_fifo::arm): Avoid improper printing of integer as
a string in debug output.
2012-12-07 20:59:44 +00:00
Christopher Faylor 0d1a50b81a * sigproc.h (sigpacket): Remove parameter names from declarations.
(sigpacket::sigtls): Rename from 'tls'.
* exceptions.cc (sigpacket::process): Define local tls variable and assign that
to sigtls if appropriate.  Clarify debugging output.
* sigproc.cc (sig_send): Accommodate tls -> sigtls rename.
(pending_signals::add): Ditto.
(wait_sig): Ditto.
2012-12-07 17:37:33 +00:00
Christopher Faylor 9873ac53d7 * cygtls.h (_cygtls::get_signal_arrived): Add parameter to make lock/unlock
conditional.
* exceptions.cc (_cygtls::interrupt_setup): Don't get a lock when setting
signal_arrived since we already have one.
* gendef: Add some comments to make it easier to find functions.
2012-12-07 17:23:22 +00:00
Yaakov Selkowitz 0ba7e5d36b * include/cygwin/wait.h (WAIT_ANY): Define.
(WAIT_MYPGRP): Define.
2012-12-06 08:32:58 +00:00
Corinna Vinschen 497826e97a * child_info.h (class child_info_spawn): Drop unused member lock.
(CURR_CHILD_INFO_MAGIC): Update.
	* sigproc.cc (child_info_spawn::child_info_spawn): Drop setting lock.
2012-12-05 10:37:17 +00:00
Christopher Faylor 3211ef434d * cygtls.h (_cygtls::will_wait_for_signal): Rename from 'signal_waiting' to
something more expressive.  Reflect rename throughout.
(_cygtls::get_signal_arrived): Rename from create_signal_arrived.  Move lock
here.
(_cygtls::set_signal_arrived): Use get_signal_arrived.
* exceptions.cc (_cygtls::interrupt_setup): Use get_signal_arrived.
* tlsoffsets.h: Regenerate.
2012-12-04 20:26:18 +00:00
Christopher Faylor 1f8fe1aa0e * spawn.cc (child_info_spawn::worker): Make detection of '/c' case insensitive
when looking for cmd.exe command line.
2012-11-30 07:11:19 +00:00
Christopher Faylor d4f4d1d0d6 ChangeLog:
2012-11-26  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* configure.ac: Rename from configure.in.
	* configure.in: Delete.
	* configure: Regenerate.

cygserver/ChangeLog:
2012-11-26  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* configure.ac: Rename from configure.in.
	* configure.in: Delete.
	* configure: Regenerate.

cygwin/ChangeLog:
2012-11-26  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* configure.ac: Rename from configure.in.
	* configure.in: Delete.
	* configure: Regenerate.

doc/ChangeLog:
2012-11-26  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* configure.ac: Rename from configure.in.
	* configure.in: Delete.
	* configure: Regenerate.

lsaauth/ChangeLog:
2012-11-26  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* configure.ac: Rename from configure.in.
	* configure.in: Delete.
	* configure: Regenerate.

testsuite/ChangeLog:
2012-11-26  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* configure.ac: Rename from configure.in.
	* configure.in: Delete.
	* configure: Regenerate.

utils/ChangeLog:
2012-11-26  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* configure.ac: Rename from configure.in.
	* configure.in: Delete.
	* configure: Regenerate.
2012-11-26 19:50:45 +00:00
Corinna Vinschen 5ab123f4aa * fhandler_registry.cc: Drop Mingw.org considerations.
* fhandler_serial.cc: Ditto.
	* fhandler_socket.cc: Ditto.
	* fhandler_tape.cc: Ditto.
	* fhandler_tty.cc: Ditto.
	* net.cc: Ditto.
	* ntdll.h: Ditto.
	* sched.cc: Ditto.
	* sec_helper.cc: Ditto.
2012-11-26 13:28:53 +00:00
Christopher Faylor 916015a6af * configure.in: Remove unneeded ALLOC substitution.
* configure: Regenerate.
* aclocal.m4: Ditto.
2012-11-23 14:58:24 +00:00
Christopher Faylor 6a432cb180 * configure.in: Add previously-missed AC_NO_EXECUTABLES.
* configure: Regenerate.
* aclocal.m4: Ditto.
2012-11-23 14:55:44 +00:00
Christopher Faylor 2e488e9543 cygwin/ChangeLog:
2012-11-23  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* Makefile.in: Use explicit path to mkdir.

lsaauth/ChangeLog:
2012-11-23  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* Makefile.in: Use /bin/mkdir to make directories.

testsuite/ChangeLog:
2012-11-23  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* Makefile.in: Remove old Makefile.common'isms.  Don't rely on
	in-build tools.
2012-11-23 14:52:07 +00:00
Christopher Faylor 4c36016b57 ChangeLog:
2012-11-12  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* Makefile.common: Revamp for new configury.  Add default compilation
	targets, include .E processing.  Add magic for allowing "CFLAGS" to
	control optimization options in "CXXFLAGS".
	* configure.cygwin: New include for Cygwin configure.in's.
	* acinclude.m4: Delete old definitions.  Implement AC_WINDOWS_HEADERS,
	AC_WINDOWS_LIBS, AC_CYGWIN_INCLUDES, target_builddir, winsup_srcdir.
	* aclocal.m4: Regenerate.
	* autogen.sh: New file.
	* ccwrap: New script.
	* c++wrap: New script.
	* config.guess: New script.
	* config.sub: New script.
	* configure: Regenerate.
	* configure.in: Eliminate LIB_AC_PROG_* calls in favor of standard.
	Delete ancient target test.
	* install-sh: New script.

cygserver/ChangeLog:
2012-11-12  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* Makefile.in: Revamp for new configury.
	* configure.in: Revamp for new configury.
	* aclocal.m4: Regenerate.
	* configure: Ditto.
	* autogen.sh: New script.

cygwin/ChangeLog:
2012-11-22  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* select.cc (select): Don't return -1 when we've timed out after
	looping.

2012-11-22  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* Makefile.in: Revamp for new configury.
	(datarootdir): Add variable setting.
	(winver_stamp): Accommodate changes to mkvers.sh setting.
	(libc.a): Fix race when libm.a might not have been built yet.
	* configure.in: Revamp for new configury.
	* aclocal.m4: Regenerate.
	* configure: Ditto.
	* autogen.sh: New script.
	* mkvers.sh: Find include directives via CFLAGS and friends rather than
	assuming that w32api lives nearby.

utils/ChangeLog:
2012-11-12  Christopher Faylor  <me.cygwin2012@cgf.cx>

	* aclocal.m4: Regenerate.
	* configure: Ditto.
	* autogen.sh: New script.
	* configure.in: Revamp for new configury.
	* Makefile.in: Revamp for new configury.  Rename ALL_* to just *.
	Always use "VERBOSE" setting.
	(MINGW_CXX): Don't include CFLAGS in definition.
	(all): Define target first, before everything else so that it is the
	default.
	(ps.exe): Don't add useless -lcygwin.
	(ldh.exe): For consistency, add to existing MINGW_LDFLAGS rather than
	redefining them.
	(cygcheck.exe): Always include -lz for MINGW_LDFLAGS.  Don't try to
	figure out where to find it.
	(dumper.exe): Simplify check.  Assume libraries are installed rather
	than trying to retrieve from source tree.
	(install): Just use /bin/mkdir to create directories.
	(Makefile): Regenerate when standard dependencies change.
	* dump_setup.cc: Always include zlib.h.  Remove accommodations for it
	possibly not existing.
	* parse_pe.cc: Add define which allows building with installed
	binutils package.
	* dumper.cc: Ditto.
2012-11-23 13:22:47 +00:00
Yaakov Selkowitz beaf1df02c * termios.cc (cfsetspeed): New function.
* cygwin.din (cfsetspeed): Export.
* posix.sgml (std-bsd): Add cfsetspeed.
* include/sys/termios.h (cfsetspeed): Declare.
* include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
2012-11-21 20:13:07 +00:00
Corinna Vinschen bd249f0177 * include/mntent.h: Only include paths.h when building for Cygwin.
Add comment to explain why.
2012-11-16 17:35:14 +00:00
Corinna Vinschen 0d963613b0 * winbase.h: Semi-reinstantiate to workaround lack inline assembler
implementation of InterlockedCompareExchange for i686 in Mingw64
	headers.
	* pinfo.cc (pinfo::init): Remove unused variable mapaddr.
2012-11-11 10:56:01 +00:00
Corinna Vinschen 2af359986f * sigproc.cc (proc_subproc): Delete unused variable child. 2012-11-08 18:41:58 +00:00
Christopher Faylor aaa812cbd0 * fhandler_termios.cc (fhandler_termios::line_edit): Don't do special character
handling when stopped by CTRL-S.
* fhandler_tty.cc (bytes_available): Add arguments to debug_only_printf call.
* sigproc.cc (proc_subproc): Simplify some if logic.
2012-11-08 17:27:00 +00:00
Yaakov Selkowitz 650dc73fa5 * include/sys/termios.h (CBRK): Define as alias of CEOL.
(CREPRINT): Define as alias of CRPRNT.
	(CDISCARD): Define as alias of CFLUSH.
	(TTYDEF_*): Define.
2012-11-05 03:19:28 +00:00
Corinna Vinschen f54898bac9 * include/sys/param.h: Include stddef.h to define NULL. 2012-10-31 16:48:50 +00:00
Corinna Vinschen 2345b582f2 * fhandler_disk_file.cc (fhandler_disk_file::rewinddir): Fix using
wrong value in condition.
2012-10-31 15:02:13 +00:00
Corinna Vinschen b120088ccd * include/sys/cygwin.h: Add missing defines for CW_ALLOC_DRIVE_MAP,
CW_MAP_DRIVE_MAP and CW_FREE_DRIVE_MAP.
2012-10-30 10:32:46 +00:00
Kai Tietz f71f133bda * dcrt0.cc (quoted): Renamed strechr to strchrnul.
* environ.cc (environ_init): Likewise.
        * sec_acl.cc (aclfromtext32): Likewise.
        * sec_auth.cc (extract_nt_dom_user): Likewise.
        * uinfo.cc (pwdgrp::next_str): Likewise.
        * string.h (strechr): Likewise.
2012-10-27 12:09:38 +00:00
Kai Tietz 0222a24fe3 * string.h (strechr): Replace assembler by
C code.
       (ascii_strcasematch): Likewise.
       (ascii_strncasematch): Likwise.
2012-10-26 20:00:12 +00:00
Corinna Vinschen 54b302310e * dir.cc (closedir): Fix syscall_printf. 2012-10-26 15:12:14 +00:00
Corinna Vinschen 422743b6ec * include/cygwin/signal.h (sigset_t): Define here. 2012-10-26 09:21:48 +00:00
Yaakov Selkowitz 478bb995fb * Makefile.in (DLL_IMPORTS): Use system import libraries for
kernel32 and ntdll instead of from in-tree w32api.
	(cygwin0.dll): Remove rule dependency on DLL_IMPORTS, as they
	are no longer built in-tree.
2012-10-24 10:12:45 +00:00
Corinna Vinschen a94555ec0f * thread.h (List_insert): Cast first parameter in
InterlockedCompareExchangePointer call to avoid compiler warnings.
	(List_remove): Ditto.
2012-10-23 10:17:29 +00:00
Corinna Vinschen b945ba6fc3 * winbase.h: Remove. 2012-10-22 17:26:45 +00:00
Corinna Vinschen b952c0c8d5 * child_info.h (CURR_CHILD_INFO_MAGIC): Update. 2012-10-22 12:45:46 +00:00
Corinna Vinschen 3f30575344 * include/cygwin/version.h (CYGWIN_VERSION_DLL_MINOR): Bump to 18. 2012-10-21 10:20:53 +00:00
Corinna Vinschen c74e68b7e2 * fhandler_floppy.cc (fhandler_dev_floppy::lseek): Remove lloffset.
Use offset directly.  Add shortcut for lseek(fd, 0, SEEK_CUR) case.
	(fhandler_dev_floppy::ioctl): Drop wrong RDSETBLK case.
	* fhandler_raw.cc (fhandler_dev_raw::ioctl): Revamp RDSETBLK code.
2012-10-16 09:52:26 +00:00
Christopher Faylor 2c9cefa586 * fhandler_tty.cc (fhandler_pty_slave::write): Fix potential exit from loop
with write mutex held.  Delete redundant mutex release.  Clear tty error once
we've grabbed it.
2012-10-15 17:12:17 +00:00
Corinna Vinschen b0b441fcef * fhandler_raw.cc (fhandler_dev_raw::fhandler_dev_raw): Drop gratuitous
initializing from previous patch.
2012-10-15 16:11:38 +00:00
Corinna Vinschen abadc07850 * fhandler_floppy.cc (fhandler_dev_floppy::open): Fix comment. 2012-10-15 14:58:39 +00:00
Christopher Faylor 744f194868 * fhandler_tty.cc (fhandler_pty_slave::write): DWORD -> BOOL. 2012-10-15 14:36:48 +00:00
Corinna Vinschen db8224e8be * fhandler.h (class fhandler_dev_raw): Add members devbufalloc and
devbufalign.
	(class fhandler_dev_floppy): Remove member bytes_per_sector;
	* fhandler_floppy.cc (bytes_per_sector): Define as devbufalign.
	(fhandler_dev_floppy::open): Set devbufalign to a multiple of the
	sector size and handle devbuf allocation and alignment in !O_DIRECT
	case here.  Change comment accordingly.
	Call FSCTL_ALLOW_EXTENDED_DASD_IO for partitions as well.
	(fhandler_dev_floppy::raw_write): Fix comment.  Rewrite and fix
	writing behaviour when application uses read and lseek.
	(fhandler_dev_floppy::lseek): Use rounddown macro.  Call
	SetFilePointerEx rather than the old SetFilePointer.
	(fhandler_dev_floppy::ioctl): Reformat switch.  Call
	IOCTL_DISK_UPDATE_PROPERTIES rather than IOCTL_DISK_UPDATE_DRIVE_SIZE
	in BLKRRPART case.  Support BLKIOMIN, BLKIOOPT, BLKPBSZGET and
	BLKALIGNOFF.
	* fhandler_raw.cc (fhandler_dev_raw::fhandler_dev_raw): Initialize
	all devbuf-related members.
	(fhandler_dev_raw::~fhandler_dev_raw): Delete devbufalloc rather than
	devbuf.
	(fhandler_dev_raw::open): Drop allocating devbuf.
	(fhandler_dev_raw::dup): Allocate devbufalloc and set devbuf to support
	new sector-aligned devbuf handling.
	(fhandler_dev_raw::fixup_after_exec): Ditto.
	* fhandler_tape.cc (fhandler_dev_tape::open): Ditto, set devbufalign
	to 1.
	* include/cygwin/fs.h (BLKIOMIN): Define.
	(BLKIOOPT): Define.
	(BLKALIGNOFF): Define.
	(BLKPBSZGET): Define.
2012-10-13 12:34:18 +00:00
Corinna Vinschen 93c9cdc1b0 * fhandler_raw.cc (fhandler_dev_raw::open): Allow O_EXCL flag, as on
Linux.
2012-10-12 13:59:45 +00:00
Christopher Faylor fe0cb31137 * fhandler_termios.cc (fhandler_termios::line_edit): Don't manipulate
output_mutex on CTRL-S/CTRL-Q to avoid a deadlock.
* fhandler_tty.cc (fhandler_pty_slave::write): Loop when output_stopped is
detected before acquiring output_mutex.  Acquire output_mutex in the loop for
each write.
* tty.h: Remove some obsolete defines.
(tty_min::output_stopped): Make 'bool'.
2012-10-12 01:19:04 +00:00
Corinna Vinschen 9b4d1964a7 * include/cygwin/in.h (struct in_addr): Guard with s_addr to avoid
potential collision with Win32 headers.
2012-10-10 08:36:33 +00:00
Christopher Faylor 64f6e90ef7 * child_info.h (child_info_spawn::has_execed): Remove unneeded synchronization. 2012-10-09 22:07:10 +00:00
Christopher Faylor 9536b817b1 * pinfo.cc: Remove unneeded assert.h. 2012-10-09 15:12:07 +00:00
Christopher Faylor ee705c1dcb * pinfo.cc (pinfo::init): Detect potential race where short block has been
retrieved but PID_EXECED flag is not set.
2012-09-17 20:07:49 +00:00
Christopher Faylor 25e5803d35 * cygthread.cc (cygthread::stub): Remove old, unnecessary, FIXMEd code.
* spawn.cc (child_info_spawn::worker): Avoid calling close_all_files() twice.
2012-09-14 03:32:52 +00:00
Corinna Vinschen 7dc5165954 * pseudo-reloc.cc (auto_protect_for): New function.
(__write_memory): Call auto_protect_for to handle page protection.
	(do_pseudo_reloc): Call auto_protect_for to restore old page protection.
2012-09-02 10:21:34 +00:00
Christopher Faylor 4acb2ffac7 * pinfo.cc (pinfo::init): Remove assertion. 2012-08-26 17:20:30 +00:00