1 2011-04-17 Christopher Faylor <me.cygwin2011@cgf.cx>
3 * cygheap.h (init_cygheap::ctty): Use base class so that console can
5 * dtable.cc (dtable::stdio_init): Remove special-case call to
7 * exceptions.cc (sigpacket::process): Conditionally flush terminal
8 input on certain signals.
9 * fhandler.h (fhandler_console::get_tty_stuff): Make non-static.
10 (fhandler_termios::get_ttyp): Move here.
11 (fhandler_termios::sigflush): Declare.
12 (fhandler_tty_common::get_ttyp): Delete.
13 * fhandler_console.cc (fhandler_console::get_tty_stuff): Pass this as
15 (set_console_ctty): Delete.
16 (tty_list::get_tty): Just return pointer to shared console region,
17 delaying get_tty_stuff until open().
18 (fhandler_console::init): Treat NULL handle as signifying that console
19 should be opened with O_NOCTTY flag. Rename handle argument to the
21 * fhandler_termios.cc (fhandler_termios::sigflush): Define.
22 * fhandler_tty.cc (handler_tty_master::init_console): Pass NULL as
23 first argument to fhandler_console::init.
24 * pinfo.cc (_pinfo::set_ctty): Change third parameter to
25 fhandler_termios *. Add extra debugging.
26 * pinfo.h (_pinfo::set_ctty): Change third parameter to
29 * sigproc.cc (handle_sigsuspend): Don't special-case non-main threads.
31 2011-04-15 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
33 * thread.cc (pthread_setschedprio): New function.
34 * include/pthread.h (pthread_setschedprio): Declare.
35 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
36 * cygwin.din (pthread_setschedprio): Export.
37 * posix.sgml (std-notimpl) Move pthread_setschedprio from here...
38 (std-susv4) ...to here.
40 2011-04-10 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
42 * fhandler_proc.cc (proc_tab): Add /proc/swaps virtual file.
43 (format_proc_swaps): New function.
45 2011-04-06 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
47 * Makefile.in: Move srcdir definition before others which uses it.
49 2011-04-06 Jon TURNEY <jon.turney@dronecode.org.uk>
51 * dll_init.cc (reserve_at, release_at): New functions.
52 (load_after_fork): If the DLL was loaded higher than the required
53 address, assume that it loaded at it's base address and also reserve
54 memory there to force it to be relocated.
56 2011-04-04 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
58 * include/cygwin/types.h: Move #include <sys/sysmacros.h> to
59 end of header so that it gets the dev_t typedef.
60 * include/sys/sysmacros.h (gnu_dev_major, gnu_dev_minor,
61 gnu_dev_makedev): Prototype and define as inline functions.
62 (major, minor, makedev): Redefine in terms of gnu_dev_*.
64 2011-04-04 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
66 * include/cygwin/types.h: Move multiple inclusion guards to
67 beginning and end of header.
69 2011-04-04 Christopher Faylor <me.cygwin2011@cgf.cx>
71 * Makefile.in: Move Makefile.common include earlier to fix problems
72 with relative ${srcdir} path which confuses make.
74 2011-04-04 Corinna Vinschen <corinna@vinschen.de>
77 * autoload.cc (DnsQuery_A): Fatal if not available.
78 (DnsRecordListFree): Ditto.
79 (DsGetDcNameW): Ditto.
80 (NetGetAnyDCName): Remove.
81 (NetGetDCName): Remove.
82 (EnumProcessModules): Fatal if not available.
83 (GetModuleFileNameExW): Ditto.
84 (GetModuleInformation): Ditto.
85 (GetProcessMemoryInfo): Ditto.
86 (QueryWorkingSet): Ditto.
87 (LsaRegisterLogonProcess): Ditto.
88 * fenv.cc (_feinitialise): Drop supports_sse condition.
89 * fhandler_disk_file.cc (path_conv::isgood_inode): Fix comment.
90 (fhandler_base::fstat_by_name): Drop has_fileid_dirinfo condition.
91 (fhandler_disk_file::opendir): Ditto.
92 * fhandler_netdrive.cc (fhandler_netdrive::readdir): Fix comment.
93 * fhandler_proc.cc (format_proc_partitions): Drop NT4-only code.
94 * fhandler_process.cc (get_process_state): Ditto.
95 * kernel32.cc (GetWindowsDirectoryW): Remove.
96 (GetWindowsDirectoryA): Remove.
97 * miscfuncs.cc (nice_to_winprio): Drop NT4-only code.
98 * mount.cc (fs_info::update): Fix comments.
99 * net.cc (get_2k_ifs): Drop NT4-only code.
100 * sec_auth.cc (get_logon_server): Ditto.
101 (lsaauth): Drop NT4-specific error handling.
102 * security.cc (alloc_sd): Set SE_DACL_PROTECTED unconditionally.
103 * select.cc (select_stuff::wait): Always use MWMO_INPUTAVAILABLE.
104 (peek_windows): Drop NT4-only condition in call to PeekMessage.
105 * syscalls.cc (gethostid): Remove NT4-only workaround.
106 * wincap.cc: Througout, drop has_dacl_protect,
107 has_broken_if_oper_status, has_process_io_counters,
108 has_terminal_services, has_extended_priority_class, has_guid_volumes,
109 has_fileid_dirinfo, has_mwmo_inputavailable and supports_sse from
111 (wincap_nt4sp4): Remove.
112 (wincap_minimal): Set to wincap_2000.
113 (wincapc::init): Rely on availability of OSVERSIONINFOEX structure.
114 Treat error from GetVersionEx as fatal. Treat NT4 as fatal.
115 * wincap.h (struct wincaps): Drop has_dacl_protect,
116 has_broken_if_oper_status, has_process_io_counters,
117 has_terminal_services, has_extended_priority_class, has_guid_volumes,
118 has_fileid_dirinfo, has_mwmo_inputavailable and supports_sse flags
120 * winlean.h (GetWindowsDirectoryW) Define as GetSystemWindowsDirectoryW.
121 (GetWindowsDirectoryA): Define as GetSystemWindowsDirectoryA.
123 2011-04-04 Corinna Vinschen <corinna@vinschen.de>
125 * dtable.cc (dtable::init_std_file_from_handle): Fix a comment to
126 reflect the current state.
128 2011-04-04 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
130 * Makefile.in (fhandler_proc_CFLAGS): Define USERNAME, HOSTNAME,
132 * fhandler_proc.cc (format_proc_version): Add build machine and GCC
133 version information as on Linux.
135 2011-04-04 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
136 Corinna Vinschen <corinna@vinschen.de>
138 * devices.h (fh_devices): Define FH_PROC_MIN_MINOR.
139 Reorder major-0 devices so that all /proc directories fall
140 between FH_PROC and FH_PROC_MIN_MINOR.
141 * path.h (isproc_dev): Redefine accordingly.
143 2011-04-04 Corinna Vinschen <corinna@vinschen.de>
145 * cygserver_setpwd.h (setlsapwd): Add username parameter to declaration.
146 * external.cc (cygwin_internal): In the CW_SET_PRIV_KEY case, fetch
147 additional username parameter.
148 * setlsapwd.cc (setlsapwd): Add username parameter. Allow admin to
149 set the hidden password for other users.
151 2011-04-04 Corinna Vinschen <corinna@vinschen.de>
153 * sec_auth.cc (get_user_groups): Mark well-known groups as well-known.
154 (get_user_local_groups): Ditto.
155 (verify_token): Drop useless label.
156 * sec_helper.cc (cygsid::get_sid): Check for well-known SID if
157 well_known isn't set.
158 * security.h (well_known_sid_type): New inline function.
160 2011-04-02 Corinna Vinschen <corinna@vinschen.de>
162 * autoload.cc (FindFirstVolumeA): Remove.
163 (FindNextVolumeA): Remove.
164 (FindVolumeClose): Remove.
165 (GetVolumeNameForVolumeMountPointA): Remove.
166 * ntdll.h (NtFlushBuffersFile): Declare.
167 * syscalls.cc (sync_worker): Rewrite using native NT functions.
170 2011-04-02 Corinna Vinschen <corinna@vinschen.de>
172 * fhandler_proc.cc (format_proc_partitions): Express length in WCHAR
175 2011-04-02 Corinna Vinschen <corinna@vinschen.de>
177 * autoload.cc (GetExtendedTcpTable): Remove.
178 (GetTcpTable): Remove.
179 (CharNextExA): Remove.
180 (FindWindowA): Remove.
181 (ShowWindowAsync): Remove.
182 * dcrt0.cc (disable_dep): Remove unused function.
183 (dll_crt0_0): Drop comment babbling about TS & DEP.
184 * fhandler_socket.cc (address_in_use): Remove unused function.
185 * wincap.cc: Throughout, drop ts_has_dep_problem from wincaps.
186 (wincapc::init): Drop code setting ts_has_dep_problem flag.
187 * wincap.h (struct wincaps): Drop ts_has_dep_problem flags and method.
189 2011-04-01 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
191 Implement /proc/sysvipc/*
192 * devices.in (dev_procsysvipc_storage): Add.
193 * devices.cc: Regenerate.
194 * devices.h (fh_devices): Add FH_PROCSYSVIPC.
195 * dtable.cc (build_fh_pc): Add case FH_PROCSYSVIPC.
196 * fhandler.h (class fhandler_procsysvipc): Declare.
197 (fhandler_union): Add __procsysvipc.
198 * fhandler_proc.cc (proc_tab): Add sysvipc virt_directory.
199 * fhandler_procsysvipc.cc: New file.
200 * Makefile.in (DLL_OFILES): Add fhandler_procsysvipc.o.
201 * path.h (isproc_dev): Add FH_PROCSYSVIPC to conditional.
203 2011-04-01 Corinna Vinschen <corinna@vinschen.de>
205 * Makefile.in (DLL_OFILES): Add avapi32.o.
206 * advapi32.cc: New file.
207 * autoload.cc: Add block of remaining advapi32 functions used by
208 Cygwin. Keep commented out. Explain why.
210 2011-04-01 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
212 * fhandler_proc.cc (format_proc_loadavg): Add running/total
213 processes as fourth component of output.
214 * fhandler_process.cc (get_process_state): Make non-static.
215 Add FIXME about generating an 'O' flag.
217 2011-04-01 Corinna Vinschen <corinna@vinschen.de>
219 * fhandler_random.cc (fhandler_dev_random::crypt_gen_random):
220 Use CryptAcquireContextW.
221 * ntdll.h (STATUS_PROCEDURE_NOT_FOUND): Define.
222 * sec_auth.cc (open_local_policy): Rename NTSTATUS variable ret to
223 status. Drop usage of LsaNtStatusToWinError.
224 (verify_token): Call NtQuerySecurityObject instead of
225 GetKernelObjectSecurity.
226 (create_token): Rename NTSTATUS variable ret to status. Rename ret2 to
227 sub_status. Drop usage of LsaNtStatusToWinError. In case LsaLogonUser
228 fails, report the sub_status as well.
230 2011-04-01 Corinna Vinschen <corinna@vinschen.de>
232 * libc/strptime.c: Remove misleading comment.
234 2011-03-31 Corinna Vinschen <corinna@vinschen.de>
236 * ntdll.h: Allow usage from plain C code.
237 (FSCTL_PIPE_IMPERSONATE): Define.
238 (enum _THREAD_INFORMATION_CLASS): Define.
239 (RTL_QUERY_REGISTRY_xxx): Define.
240 (RTL_REGISTRY_xxx): Define.
241 (PRTL_QUERY_REGISTRY_ROUTINE): Define.
242 (struct _RTL_QUERY_REGISTRY_TABLE): Define.
243 (enum _KEY_VALUE_INFORMATION_CLASS): Define.
244 (struct _KEY_VALUE_PARTIAL_INFORMATION): Define.
245 (NtAccessCheck): Declare.
246 (NtAllocateLocallyUniqueId): Declare.
247 (NtCreateKey): Declare.
248 (NtDuplicateToken): Declare.
249 (NtLoadKey): Declare.
250 (NtOpenKey): Declare.
251 (NtOpenProcessToken): Declare.
252 (NtOpenThreadToken): Declare.
253 (NtPrivilegeCheck): Declare.
254 (NtQueryInformationToken): Declare.
255 (NtQueryValueKey): Declare.
256 (NtSetInformationThread): Declare.
257 (NtSetInformationToken): Declare.
258 (NtSetValueKey): Declare.
259 (RtlAbsoluteToSelfRelativeSD): Declare.
260 (RtlAddAccessAllowedAce): Declare.
261 (RtlAddAccessDeniedAce): Declare.
262 (RtlAddAce): Declare.
263 (RtlCheckRegistryKey): Declare.
264 (RtlCopySid): Declare.
265 (RtlCreateAcl): Declare.
266 (RtlCreateRegistryKey): Declare.
267 (RtlCreateSecurityDescriptor): Declare.
268 (RtlEqualPrefixSid): Declare.
269 (RtlEqualSid): Declare.
270 (RtlFirstFreeAce): Declare.
271 (RtlGetAce): Declare.
272 (RtlGetDaclSecurityDescriptor): Declare.
273 (RtlGetGroupSecurityDescriptor): Declare.
274 (RtlGetOwnerSecurityDescriptor): Declare.
275 (RtlIdentifierAuthoritySid): Declare.
276 (RtlInitializeSid): Declare.
277 (RtlLengthSid): Declare.
278 (RtlQueryRegistryValues): Declare.
279 (RtlSetControlSecurityDescriptor): Declare.
280 (RtlSetDaclSecurityDescriptor): Declare.
281 (RtlSetGroupSecurityDescriptor): Declare.
282 (RtlSetOwnerSecurityDescriptor): Declare.
283 (RtlSubAuthorityCountSid): Declare.
284 (RtlSubAuthoritySid): Declare.
285 (RtlWriteRegistryValue): Declare.
287 2011-03-31 Corinna Vinschen <corinna@vinschen.de>
289 * uinfo.cc (cygheap_user::init): Don't call GetUserName. Fetch username
290 from Windows environment instead. Explain why.
291 (cygheap_user::env_domain): Use MAX_DOMAIN_NAME_LEN rather than DNLEN
292 to specify the size of the domain name buffer.
294 2011-03-30 Corinna Vinschen <corinna@vinschen.de>
296 * hires.h: Fix copyright.
298 (FACTOR): Add comment.
300 (JITTER): New definition. Comment.
301 (systime_ns): Avoid gratuitous copying of the value returned by
302 GetSystemTimeAsFileTime.
303 (corelocaltime, localtime, gmtime): Remove very old, unused code block.
304 (cygwin_tzset): Remove.
305 (hires_ms::timeGetTime_ns): Add missing semicolon in comment.
306 (hires_ms::nsecs): Redefine check for difference between internal
307 timer value and system time.
309 2011-03-30 Corinna Vinschen <corinna@vinschen.de>
311 * times.cc (hires_ms::resolution): Make sure resolution is never 0.
312 (clock_setres): Ditto.
314 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
316 * cygtls.h (struct _local_storage): Redefine process_ident as wchar_t
318 * syslog.cc (CYGWIN_LOG_NAME): Convert to wide char constant.
319 (openlog): Convert incoming ident string to wide char. Fix formatting.
320 (vsyslog): Print ident string as wide char string. Convert message
321 string to wide char and call UNICODE Win32 Event functions to make sure
322 to use correct codeset.
323 * tlsoffset.h: Regenerate.
325 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
327 * fhandler_socket.cc (get_inet_addr): Make externally available.
328 * autoload.cc (GetUdpTable): Define.
329 * syslog.cc (connect_syslogd): Use get_inet_addr rather than _stat64
330 to check for local socket file. Create socket with type returned by
331 get_inet_addr. If connect on UDP socket works, test if there's
332 really a listening peer, otherwise fall back to Windows event log.
333 (try_connect_syslogd): Use syslogd_inited flag to check if syslogd
336 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
338 * uinfo.cc (cygheap_user::env_domain): Use LookupAccountSidW and
339 convert user and domain to multibyte strings to make sure to use
342 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
344 * autoload.cc (UuidCreate): Remove.
345 (UuidCreateSequential): Remove.
346 * passwd.cc (internal_getpwsid): Avoid a strict-aliasing compiler
347 error with gcc 4.5.1.
348 * fhandler_floppy.cc (fhandler_dev_floppy::get_drive_info): Ditto.
349 * ntdll.h (NtAllocateUuids): Declare.
350 * syscalls.cc (gethostid): Use NtAllocateUuids function rather than
351 UuidCreateSequential/UuidCreate to get rid of rpcrt4 dependency.
353 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
355 * cygwin.din (pthread_spin_destroy): Export.
356 (pthread_spin_init): Export.
357 (pthread_spin_lock): Export.
358 (pthread_spin_trylock): Export.
359 (pthread_spin_unlock): Export.
360 * posix.sgml (std-susv4): Add pthread_spin_destroy, pthread_spin_init,
361 pthread_spin_lock, pthread_spin_trylock, pthread_spin_unlock.
362 (std-notimpl): Remove pthread_spin_[...].
363 * pthread.cc (pthread_spin_init): New function.
364 * thread.cc (pthread_spinlock::is_good_object): New function.
365 (pthread_mutex::pthread_mutex): Rearrange initializers to accommodate
366 protected data in pthread_mutex.
367 (pthread_spinlock::pthread_spinlock): New constructor.
368 (pthread_spinlock::lock): New method.
369 (pthread_spinlock::unlock): New method.
370 (pthread_spinlock::init): New method.
371 (pthread_spin_lock): New function.
372 (pthread_spin_trylock): New function.
373 (pthread_spin_unlock): New function.
374 (pthread_spin_destroy): New function.
375 * thread.h (PTHREAD_SPINLOCK_MAGIC): Define.
376 (class pthread_mutex): Change access level of members shared with
377 derived classes to protected.
378 (pthread_mutex::set_shared): New protected method.
379 (class pthread_spinlock): New class, derived class of pthread_mutex.
380 * include/pthread.h (pthread_spin_destroy): Declare.
381 (pthread_spin_init): Declare.
382 (pthread_spin_lock): Declare.
383 (pthread_spin_trylock): Declare.
384 (pthread_spin_unlock): Declare.
385 * include/cygwin/types.h (pthread_spinlock_t): New typedef.
386 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
388 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
390 * net.cc (SIO_BASE_HANDLE): Define.
391 (fdsock): If we got an LSP handle, try to create a copy of the base
392 handle instead. Change comment to explain.
394 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
396 * include/cygwin/version.h: Bump CYGWIN_VERSION_DLL_MINOR to 10.
398 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
400 * autoload.cc (winmm): Remove time functions. Don't treat
401 unloadable wave functions as fatal.
402 * hires.h (hires_ms::timeGetTime_ns): New private method.
403 (hires_ms::dmsecs): Call timeGetTime_ns here.
404 * ntdll.h (struct _KSYSTEM_TIME): Define.
405 (KUSER_SHARED_DATA): Redefine to allow access to InterruptTime.
406 (SharedUserData): Define here.
407 (NtQueryTimerResolution): Declare.
408 (NtSetTimerResolution): Declare.
409 * path.cc (SharedUserData): Move to ntdll.h.
410 * times.cc (hires_ms::timeGetTime_ns): New private method.
411 Use throughout instead of timeGetTime. Document entire functionality
412 of timeGetTime in case we need it.
413 (hires_ms::resolution): Try a call to NtQueryTimerResolution
414 to fetch current period. Fall back to heuristic if that fails.
415 Cast to DWORD in assignments to minperiod.
416 (clock_setres): Align period to possible values per a call to
417 NtQueryTimerResolution. Explain why. Replace calls to timeBeginPeriod
418 and timeEndPeriod with underlying call to NtSetTimerResolution. Use
419 status code from NtSetTimerResolution to compute errno.
420 Convert period to ULONGLONG and store 100ns value to simplify code.
422 2011-03-29 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
423 Corinna Vinschen <corinna@vinschen.de>
425 * include/sys/xattr.h: New file.
427 2011-03-28 Jon TURNEY <jon.turney@dronecode.org.uk>
429 * thread.cc (semaphore::init, destroy, close): Standards conformance
430 fix. On a failure, return -1 and set errno.
431 * thread.h (semaphore::terminate): Save errno since semaphore::close()
434 2011-03-27 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
436 * cygwin.din (strchrnul): Export.
437 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
438 * posix.sgml (std-gnu): Add strchrnul.
440 2011-03-27 Christopher Faylor <me.cygwin2011@cgf.cx>
442 * dll_init.cc (dll::init): Accommodate ill-behaved dlls who don't fill
445 2011-03-25 Corinna Vinschen <corinna@vinschen.de>
447 * mmap.cc (mmap64): Add a cheat to let a certain autoconf test succeed
448 on 64 bit systems. Explain why.
450 2011-03-23 Christopher Faylor <me.cygwin2011@cgf.cx>
452 * wincap.cc (wincap_2003): Set use_dont_resolve_hack to true.
454 2011-03-23 Christopher Faylor <me.cygwin2011@cgf.cx>
456 * autoload.cc (dll_load): Change error message to make it clear if a
457 newer DLL is being run.
459 2011-03-20 Corinna Vinschen <corinna@vinschen.de>
461 * fenv.cc (_feinitialise): Don't use SSE instructions on systems not
463 * wincap.h (wincaps::supports_sse): New element.
464 * wincap.cc: Implement above element throughout.
466 2011-03-18 Corinna Vinschen <corinna@vinschen.de>
468 * cygwin.sc: Raise default cygheap size to 2 Megs.
470 2011-03-18 Christopher Faylor <me.cygwin2011@cgf.cx>
472 * fhandler.h (DEFAULT_PIPEBUFSIZE): Reset to 64K.
474 2011-03-18 Corinna Vinschen <corinna@vinschen.de>
476 * mmap.cc (mmap_record::alloc_fh): Initialize name strings in fdev to
477 empty strings or suffer a SEGV. Drop second parameter in call to
480 2011-03-18 Corinna Vinschen <corinna@vinschen.de>
482 * mmap.cc (class mmap_record): Pack 4 byte-aligned. Convert member dev
484 (mmap_record::alloc_fh): Create temporary device from dev and use in
485 call to build_fh_dev.
487 2011-03-18 Corinna Vinschen <corinna@vinschen.de>
489 * mmap.cc (mmap_record::page_map): Define as variable array rather than
491 (mmap_record::alloc_page_map): Remove.
492 (mmap_record::free_page_map): Remove.
493 (mmap_record::init_page_map): New method.
494 (mmap_record::add_record): Take mmap_record parameter by reference
495 rather than by value.
496 (mmap_record::map_pages): Fix comment.
497 (mmap_list::add_record): Allocate space for mmap_record including the
498 page_map in a single ccalloc call. Call init_page_map afterwards.
499 (mmap_list::del_record): Remove call to mmap_record::free_page_map.
501 2011-03-16 Corinna Vinschen <corinna@vinschen.de>
503 * crt0.c (mainCRTStartup): Move call to _feinitialise from here...
504 * dcrt0.cc (_dll_crt0): ...to here.
506 2011-03-16 Corinna Vinschen <corinna@vinschen.de>
508 * winver.rc: Fix copyright dates.
510 2011-03-14 Corinna Vinschen <corinna@vinschen.de>
512 * fhandler_disk_file.cc (fhandler_base::fstat_by_handle): Only use
513 file id as inode number if it masters the isgood_inode check.
515 2011-03-13 Christopher Faylor <me.cygwin2011@cgf.cx>
517 * fhandler.cc (fhandler_base_overlapped::wait_overlapped): Remove
518 special treatment for ERROR_NO_SYSTEM_RESOURCES. Cancel I/O and reset
519 the overlapped handle on error.
520 (fhandler_base_overlapped::write_overlapped): Limit writes to
521 max_atomic_write bytes in blocking case. Incorporate code from
522 now-defunct write_overlapped_fallback. Fix serious oversight where ptr
523 was not advanced as buffer was written.
524 (fhandler_base_overlapped::write_overlapped_fallback): Eliminate.
525 * fhandler.h (fhandler_base_overlapped::write_overlapped_fallback):
526 Ditto for declaration.
527 (DEFAULT_PIPEBUFSIZE): Lower size to slightly less than documented
528 worst-case atomic write size.
529 (fhandler_overlapped::wait_return): Remove unused element.
531 2011-03-09 Christopher Faylor <me.cygwin2011@cgf.cx>
533 * fhandler.cc (fhandler_base_overlapped::wait_overlapped): Handle
534 overlapped_fallback error condition like other error conditions. Set
535 res carefully and specifically for each condition rather than resorting
537 (fhandler_base_overlapped::write_overlapped): Preserve errno in
538 overlapped_fallback condition. Correct write_overlapped_fallback to
539 avoid inappropriate looping.
540 (fhandler_base_overlapped::write_overlapped_fallback): Add some more
543 2011-03-09 Christopher Faylor <me.cygwin2011@cgf.cx>
545 * fhandler.cc (fhandler_base_overlapped::write_overlapp): Oops!
546 Accommodate change in arguments to wait_overlapped.
548 2011-03-09 Christopher Faylor <me+cygwin@cgf.cx>
550 * errno.cc (errmap): Change mapping of NO_SYSTEM_RESOURCES to EFBIG.
551 * fhandler.cc (MAX_OVERLAPPED_WRITE_LEN): New constant.
552 (MIN_OVERLAPPED_WRITE_LEN): Ditto.
553 (fhandler_base_overlapped::close): Accommodate change in arguments to
555 (fhandler_base_overlapped::setup_overlapped): Add __stdcall and regparm
557 (fhandler_base_overlapped::destroy_overlapped): Ditto.
558 (fhandler_base_overlapped::has_ongoing_io): Ditto.
559 (fhandler_base_overlapped::wait_overlapped): Modify to return an enum
560 returning various states. Accept nonblocking parameter.
561 (fhandler_base_overlapped::read_overlapped): Add __stdcall and regparm
562 modifiers. Rework to attempt to be smarter about reacting to states
563 returned by wait_overlapped.
564 (fhandler_base_overlapped::write_overlapped): Ditto. Add fallback
565 option for when wait_overlapped detects that smaller chunks must be
567 (fhandler_base_overlapped::write_overlapped_fallback): Ditto.
568 * fhandler.h (DEFAULT_PIPEBUFSIZE): Move definition here from pipe.cc.
569 (fhandler_base::has_ongoing_io): Define with __stdcall and regparm
571 (fhandler_base_overlapped::wait_return): New enum.
572 (fhandler_base_overlapped::max_atomic_write): New variable.
573 (fhandler_base_overlapped:: wait_overlapped): Accommodate changes
574 mentioned above to arguments and modifiers.
575 (fhandler_base_overlapped::setup_overlapped): Ditto for modifiers.
576 (fhandler_base_overlapped::read_overlapped): Ditto.
577 (fhandler_base_overlapped::write_overlapped): Ditto.
578 (fhandler_base_overlapped::destroy_overlapped): Ditto.
579 (fhandler_base_overlapped::has_ongoing_io): Ditto.
580 (fhandler_base_overlapped::fhandler_base_overlapped): Zero
582 * fhandler_fifo.cc (fhandler_fifo::fhandler_fifo): Set max_atomic_write
583 to the size of the DEFAULT_PIPEBUFSIZE.
584 (fhandler_fifo::wait): Accommodate change in arguments to
586 * pipe.cc (fhandler_pipe::fhandler_pipe): Set max_atomic_write to the
587 size of the DEFAULT_PIPEBUFSIZE.
588 (fhandler_pipe::create_selectable): Allow minimum size of DEFAULT_PIPEBUFSIZE.
589 (DEFAULT_PIPEBUFSIZE): Delete here, move to fhandler.h.
591 2011-03-08 Corinna Vinschen <corinna@vinschen.de>
593 * security.cc: Fix copyright dates.
595 2011-03-08 Corinna Vinschen <corinna@vinschen.de>
597 * fhandler.cc (fhandler_base::open): When creating a file on a
598 filesystem supporting ACLs, create the file with WRITE_DAC access.
600 * fhandler_disk_file.cc (fhandler_disk_file::mkdir): Ditto for
602 * fhandler_socket.cc (fhandler_socket::bind): Ditto for sockets.
603 * path.cc (symlink_worker): Ditto for symlinks.
604 * security.cc (get_file_sd): Always call GetSecurityInfo for directories
605 on XP and Server 2003. Improve comment to explain why.
606 (set_file_attribute): Explicitely cast mode_t value to bool in call to
608 * wincap.h (wincaps::use_get_sec_info_on_dirs): New element.
609 * wincap.cc: Implement above element throughout.
611 2011-03-04 Corinna Vinschen <corinna@vinschen.de>
613 * fhandler_procsys.cc (fhandler_procsys::exists): Rewrite.
614 (fhandler_procsys::fill_filebuf): Fill buffer with valid string even if
615 reading the symlink fails.
617 2011-03-03 Corinna Vinschen <corinna@vinschen.de>
619 * posix_ipc.cc (ipc_cond_timedwait): If ipc_mutex_unlock fails, return
621 (_mq_send): Break loop if ipc_cond_timedwait returns with error.
622 (_mq_receive): Ditto.
624 2011-03-03 Corinna Vinschen <corinna@vinschen.de>
626 * errno.cc (__xpg_strerror_r): Add accidentally missing condition.
628 2011-03-02 Corinna Vinschen <corinna@vinschen.de>
630 * fhandler_procsys.cc (fhandler_procsys::open): Call worker exists
631 method, rather than wrapper.
633 2011-03-01 Christopher Faylor <me+cygwin@cgf.cx>
635 * autoload.cc (dll_load): Avoid in_forkee test since this apparently
636 fails even when not forked.
638 2011-03-01 Christopher Faylor <me+cygwin@cgf.cx>
640 * include/cygwin/version.h: Bump CYGWIN_VERSION_DLL_MINOR to 9.
642 2011-02-28 Christopher Faylor <me+cygwin@cgf.cx>
644 * autoload.cc (dll_load): Only perform DONT_RESOLVE_DLL_REFERENCES hack
645 on systems which need it.
646 * wincap.cc (use_dont_resolve_hack): Set as appropriate.
647 * wincap.h (use_dont_resolve_hack): Define.
649 2011-02-28 Christopher Faylor <me+cygwin@cgf.cx>
651 * autoload.cc (dll_load): Make inline. Clarify logic.
653 2011-02-27 Corinna Vinschen <corinna@vinschen.de>
655 * autoload.cc (dll_load): Only call LoadLibraryExW with
656 DONT_RESOLVE_DLL_REFERENCES if a normal LoadLibrary call failed with
657 ERROR_INVALID_ADDRESS.
658 (LsaRegisterLogonProcess): Align comment to previous change.
660 2011-02-26 Christopher Faylor <me+cygwin@cgf.cx>
662 * autoload.cc: Use LoadDLLfuncEx3 for all winmm functions. Accommodate
663 changes to LoadDLLprime.
664 (LoadDLLprime): Take an extra argument indicating whether this dll
665 needs special handling on fork. Place this information in the "handle"
667 (LoadDLLfuncEx3): Eliminate "func" handling. Pass new
668 no_resolve_on_fork argument to LoadDLLprime.
669 (dll_load): New function.
670 (std_dll_init): Accommodate changes to dll_info::handle. Use dll_load
671 to load DLL in both cases where it is used.
673 2011-02-26 Corinna Vinschen <corinna@vinschen.de>
675 * autoload.cc: Make autoloaded ntdll function non-optional. Ditto for
676 secur32 functions, except for LsaRegisterLogonProcess. Change return
677 value to ERROR_PROC_NOT_FOUND. Explain why.
678 * sec_auth.cc (lsaauth): Handle ERROR_PROC_NOT_FOUND from call to
679 LsaRegisterLogonProcess when generating the errno value.
681 2011-02-22 Corinna Vinschen <corinna@vinschen.de>
683 * dcrt0.cc: Fix copyright dates.
685 * syscalls.cc (_read): Move EXPORT_ALIAS to its rightful place.
687 2011-02-21 Christopher Faylor <me+cygwin@cgf.cx>
689 * cygwin.din: Mark __assert* and _abort as NOSIGFE.
691 2011-02-21 Corinna Vinschen <corinna@vinschen.de>
693 * fhandler_socket (fhandler_socket::readv): Call recv_internal directly,
695 (fhandler_socket::writev): Call send_internal directly, rather than
697 * net.cc (cygwin_recv): Call fhandler_socket::recvfrom directly, rather
698 than cygwin_recvfrom.
699 (cygwin_send): Call fhandler_socket::sendto directly, rather than
702 2011-02-20 Christopher Faylor <me+cygwin@cgf.cx>
704 * fhandler.cc (fhandler_base_overlapped::close): Finish any pending I/O
706 (fhandler_base_overlapped::wait_overlapped): Defensively zero bytes
707 read. Add more info to debugging output.
709 2011-02-18 Christopher Faylor <me+cygwin@cgf.cx>
711 * dcrt0.cc (dll_crt0_1): Add a CYGHEAP_DEBUG conditional for debugging
712 which allocates a lot of space at startup.
714 2011-02-18 Corinna Vinschen <corinna@vinschen.de>
716 * cygwin.sc: Set alignment of .cygheap section to 64K.
718 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
720 * spawn.cc (spawn_guts): Only set PID_NOTCYGWIN in _P_OVERLAY mode.
721 Drop flag if creating new process failed.
723 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
725 * Throughout fix copyright dates.
727 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
729 * devices.in: Throughout use slashes instead of backslashes in the
730 native path of devices not backed by native NT devices.
731 * devices.cc: Regenerate.
732 * globals.cc (ro_u_pmem): Use correct case.
733 (ro_u_globalroot): New R/O unicode string.
734 * path.cc (path_conv::check): Fix incorrect handling of /proc/sys
735 block devices if they are just visited due to a component check.
736 (symlink_info::posixify): Fix typo in comment.
737 (cygwin_conv_path): Use ro_u_globalroot instead of string constant.
738 (fast_cwd_version): New shared variable to store FAST_CWD version
740 (find_fast_cwd_pointer): Rename from find_fast_cwd_pointers. Don't
741 set global fast_cwd_ptr pointer here. Return pointer value instead.
742 (find_fast_cwd): New function to set fast_cwd_ptr and fast_cwd_version.
743 (cwdstuff::override_win32_cwd): Call find_fast_cwd from here.
744 Check for fast_cwd_version to differ between old and new FAST_CWD
745 structure. Check old_cwd for NULL to avoid SEGV. Don't set CWD if
746 we have neitehr a valid fast_cwd_ptr, nor a valid CWD handle in the
747 process parameter block.
748 (cwdstuff::set): Create Win32 path taking /proc/sys paths into account.
749 * spawn.cc (spawn_guts): Recode creating runpath. Also take /proc/sys
750 paths into account. Drop special CWD handling when starting non-Cygwin
753 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
755 * fhandler_procsys.cc (fhandler_procsys::opendir): Avoid SEGV if
756 opening object directory fails.
757 * fhandler_virtual.cc (fhandler_virtual::opendir): Don't leak memory.
759 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
761 * fhandler_disk_file.cc (fhandler_disk_file::readdir_helper): Don't
762 append slash if there is one already.
764 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
766 Revert change from 2010-08-31:
767 * path.cc (normalize_posix_path): Drop support for //./ and //?/
769 (path_conv::check): Ditto.
771 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
773 * fhandler_disk_file.cc (fhandler_disk_file::readdir_helper): Use POSIX
774 path to check for symlink.
776 2011-02-14 Corinna Vinschen <corinna@vinschen.de>
778 * config/i386/profile.h: Sync with Mingw.
780 2011-02-13 Corinna Vinschen <corinna@vinschen.de>
782 * path.cc (struct _FAST_CWD): Redefine to new layout used since patch
783 for KB 2393802. Adjust comments throughout.
784 (struct _FAST_CWD_OLD): Rename former definition.
785 (cwdstuff::override_win32_cwd): Check if the OS is using the old or the
786 new FAST_CWD structure layout and handle accordingly.
788 2011-02-11 Christopher Faylor <me+cygwin@cgf.cx>
790 * mkstatic: Make sure that we are not cd'ed to temporary directory on
791 exit to avoid bogus warnings on directory cleanup.
795 2011-02-11 Christopher Faylor <me+cygwin@cgf.cx>
797 * cygwin.sc: Eliminate __cygheap_mid.
800 2011-02-11 Christopher Faylor <me+cygwin@cgf.cx>
802 * cygheap.cc (_cygheap_mid): Drop unneeded section attribute.
803 (cygheap_init): Just zero cygheap structure.
804 * cygwin.sc: Keep 16 byte alignment but drop all other alignments
805 related to cygheap. Eliminate unused __cygheap_end1.
807 2011-02-11 Corinna Vinschen <corinna@vinschen.de>
809 * cygwin.sc: Raise default cygheap size to 1 Meg. Set alignment to
812 2011-02-11 Corinna Vinschen <corinna@vinschen.de>
814 * include/endian.h: Move definitions of __BIG_ENDIAN, __LITTLE_ENDIAN,
815 and __BYTE_ORDER into ...
816 * include/bits/endian.h: New file.
817 * include/arpa/nameser_compat.h: Include endian.h rather than defining
819 * include/asm/byteorder.h: Include bits/endian.h. Drop definition of
821 * include/netinet/ip.h: Include bits/endian.h. Drop definitions of
822 BIG_ENDIAN, LITTLE_ENDIAN, and BYTE_ORDER. Use underscored variants
823 of aforementioned constants.
824 * include/netinet/tcp.h: Ditto.
825 * include/sys/param.h: Drop disabled definitions of BIG_ENDIAN,
826 LITTLE_ENDIAN, and BYTE_ORDER.
828 * include/netinet/ip.h: Reformat. Define setsockopt IP_TOS options
829 matching recent RFCs. Tweak comments.
831 2011-02-10 Eric Blake <eblake@redhat.com>
833 * errno.cc (includes): Avoid compilation failure if <string.h>
834 settles on wrong strerror_r signature.
836 * errno.cc (__xpg_strerror_r): New function.
837 (strerror_r): Update to copy newlib's fixes.
838 (strerror): Set errno on failure.
839 (_sys_errlist): Cause EINVAL failure for reserved values.
840 * cygwin.din: Export new function.
841 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Combine
844 2011-02-09 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
846 * cygwin.din (pthread_yield): Export as alias to sched_yield.
847 * include/pthread.h (pthread_yield): Declare.
848 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
849 * posix.sgml (std-deprec): Add pthread_yield.
851 2011-02-09 Christopher Faylor <me+cygwin@cgf.cx>
853 * cygheap.cc: Add some __stdcall decoration where appropriate.
854 * lib/cygwin_crt0.c: __attribute -> __attribute__.
856 2011-02-09 Christopher Faylor <me+cygwin@cgf.cx>
858 * hookapi.cc (hook_or_detect_cygwin): Prevent i from being considered
859 uninitialized by gcc.
861 2011-02-09 Christopher Faylor <me+cygwin@cgf.cx>
863 * exception.h: Remove DEBUG_EXCEPTION left over debugging ifdef.
865 2011-02-08 Christopher Faylor <me+cygwin@cgf.cx>
867 * dll_init.cc: Fix typo in comment.
869 2011-02-07 Corinna Vinschen <corinna@vinschen.de>
871 * configure.in: Remove AC_ALLOCA test and test for __builtin_memset.
872 * configure: Regenerate.
874 2011-02-07 Corinna Vinschen <corinna@vinschen.de>
876 * fhandler_console.cc (fhandler_console::write_normal): Remove
877 erroneous premature return after collecting truncated multibyte
878 sequence in trunc_buf. Rather fall through to printing routine.
879 Fix return value to take trunc_buf content into account. Improve
882 2011-02-05 Christopher Faylor <me+cygwin@cgf.cx>
884 * autoload.cc (wsock_init): Properly define WSAStartup function pointer
885 to avoid stack damage.
887 2011-02-02 Corinna Vinschen <corinna@vinschen.de>
889 * libc/bsdlib.cc: Include err.h.
891 2011-02-02 Eric Blake <eblake@redhat.com>
893 * include/err.h: Fix loss of semicolons in previous patch.
895 2011-02-02 Corinna Vinschen <corinna@vinschen.de>
897 * include/err.h (err): Add noreturn attribute.
902 2011-02-02 Corinna Vinschen <corinna@vinschen.de>
904 * path.cc (conv_path_list): Remove enclosing quotes and trailing
905 backslashes from Win32 environment path lists.
907 2011-02-01 Christian Franke <franke@computer.org>
909 * fhandler.cc (fhandler_base::fsync): Ignore ERROR_INVALID_FUNCTION
910 error from FlushFileBuffers().
912 2011-01-31 Corinna Vinschen <corinna@vinschen.de>
914 * syscalls.cc (utmp_data): Fix potential buffer overflow.
916 2011-01-31 Corinna Vinschen <corinna@vinschen.de>
918 * fhandler_socket.cc (address_in_use): Improve comment readability.
920 2011-01-30 Corinna Vinschen <corinna@vinschen.de>
922 * fhandler_socket.cc (address_in_use): Disable. Add comment.
923 (fhandler_socket::bind): Change comment to explain setting the
924 SO_EXCLUSIVEADDRUSE socket option. Remove code which checks for
926 * net.cc (cygwin_setsockopt): Never set SO_REUSEADDR option. Improve
927 comment to compensate for the deleted comment in fhandler_socket::bind.
928 * wincap.cc: Throughout, drop has_enhanced_socket_security from wincaps.
929 * wincap.h (struct wincaps): Drop has_enhanced_socket_security flags
932 2011-01-28 Peter Foley <jpfoley2@verizon.net>
934 * configure.in: Define LIBSERVER regardless of cross_host.
935 * configure: Regenerate.
937 2011-01-28 Corinna Vinschen <corinna@vinschen.de>
939 * fhandler_socket.cc (fhandler_socket::wait_for_events): Call
940 pthread_testcancel in case of timeout to enable pthread_cancel
943 2011-01-27 Corinna Vinschen <corinna@vinschen.de>
945 * include/features.h (__STDC_ISO_10646__): Move to newlib's
948 2011-01-26 Corinna Vinschen <corinna@vinschen.de>
950 * fhandler_disk_file.cc (fhandler_base::fstat_by_nfs_ea): Fix
951 computation of st_blocks.
952 (fhandler_base::fstat_helper): Fix formatting.
954 2011-01-24 Corinna Vinschen <corinna@vinschen.de>
956 * include/features.h (__STDC_ISO_10646__): Define. Add comment.
958 2011-01-21 Corinna Vinschen <corinna@vinschen.de>
960 * syscalls.cc (rename): Fix permission problem with symlinks on NFS.
961 Rework how NtOpenFile gets called to make it more readable. Change
964 2011-01-20 Corinna Vinschen <corinna@vinschen.de>
966 * exec.cc: Include pinfo.h.
967 * winf.h: Move definitions of _P_PATH_TYPE_EXEC and _P_MODE from here...
968 * pinfo.h: ...to here.
969 (_P_PATH_TYPE_EXEC): Redefine to be bigger than _P_SYSTEM.
970 (_P_MODE): Redefine so as not to mask out _P_SYSTEM.
971 * spawn.cc (spawnlp): Add _P_PATH_TYPE_EXEC flag in call to spawnve.
975 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
977 * spawn.cc (av::fixup): Reenable #! handling for all exec functions.
978 Return ENOEXEC in !p_type_exec case only for unrecognized files.
979 Fix comment formatting.
981 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
983 * exec.cc (execlp): Add missing _P_PATH_TYPE_EXEC flag in call to
986 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
988 * exec.cc: Rearrange functions in alphabetical order.
989 (_execve): Drop temporary define and drop export alias.
990 (execl): Call spawnve.
991 (execle): New function.
992 (execlp): New function.
993 (execv): Call spawnve.
994 (execve): Drop converting NULL envp to emtpy envp.
995 (execvp): Call spawnve.
996 (execvpe): Drop converting NULL envp to emtpy envp. Call spawnve.
997 (fexecve): Call spawnve.
998 * spawn.cc (spawnve): Convert NULL envp to emtpy envp. Remove outdated
1000 (spawnlp): Call spawnve.
1003 (spawnvpe): Fix formatting.
1005 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
1007 * exec.cc (strccpy): Move function from here...
1008 * strfuncs.cc (strccpy): ...to here.
1009 * string.h (strccpy): Declare.
1010 * winsup.h (strccpy): Drop declaration.
1012 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
1014 * errno.cc (errmap): Add error codes for invalid binaries.
1015 * exec.cc (execvp): Call spawnve with _P_PATH_TYPE_EXEC flag
1018 * spawn.cc (spawn_guts): Filter _P_PATH_TYPE_EXEC from mode and
1019 store in p_type_exec. Call av::fixup with addtional p_type_exec
1021 (spawnve): Check for filtered mode.
1022 (spawnvpe): Add _P_PATH_TYPE_EXEC flag when calling spawnve.
1023 (av::fixup): Accept additional bool parameter p_type_exec. Only check
1024 for script if p_type_exec is true.
1025 * winf.h (_P_PATH_TYPE_EXEC): Define.
1027 (av::fixup): Declare with additional bool parameter.
1029 2011-01-17 Corinna Vinschen <corinna@vinschen.de>
1031 * fhandler_proc.cc (format_proc_partitions): Fix compiler warning.
1033 2011-01-17 Corinna Vinschen <corinna@vinschen.de>
1035 * path.cc (path_conv::check): Don't follow reparse point symlinks if
1036 PC_SYM_NOFOLLOW_REP flag is set.
1037 (cygwin_conv_path): Set PC_SYM_NOFOLLOW_REP flag when converting from
1039 * path.h (enum pathconv_arg): Define PC_SYM_NOFOLLOW_REP flag.
1041 2011-01-17 Corinna Vinschen <corinna@vinschen.de>
1043 * fhandler_proc.cc (proc_tab_cmp): Fix typo in comment.
1044 (fhandler_proc::fill_filebuf): Handle return value of 0 from format
1046 (format_proc_stat): Set errno when returning 0 size.
1047 (format_proc_partitions): Rewrite method to fetch partition info.
1049 2011-01-13 Corinna Vinschen <corinna@vinschen.de>
1051 * fhandler_disk_file.cc (fhandler_base::fstat_helper): Always set
1052 st_size of directories to 0. Explain why.
1054 2011-01-12 Corinna Vinschen <corinna@vinschen.de>
1056 * posix.sgml: Add madvise to BSD list.
1058 2011-01-12 Corinna Vinschen <corinna@vinschen.de>
1060 * cygwin.din (madvise): Export posix_madvise as madvise.
1061 * include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR.
1062 * include/sys/mman.h: Define madvise constants, keep Linux-specific
1063 constants undefined.
1066 2011-01-12 Corinna Vinschen <corinna@vinschen.de>
1068 * fhandler.h (struct part_t): New type.
1069 (class fhandler_dev_floppy): Convert partitions to part_t pointer.
1070 Add lock_partition method.
1071 * fhandler_floppy.cc (fhandler_dev_floppy::lock_partition): New method
1072 to implement ondemand partition locking.
1073 (fhandler_dev_floppy::write_file): Call lock_partition from here if
1074 writing failed due to a potential write restriction on a disk
1076 (fhandler_dev_floppy::open): Don't lock partitions here.
1077 (fhandler_dev_floppy::close): Keep track of partition handle reference
1078 count. Close handles and remove partitions pointer ony if count is 0.
1079 (fhandler_dev_floppy::dup): Just copy partitions pointer and increment
1082 2011-01-11 Corinna Vinschen <corinna@vinschen.de>
1084 * fhandler.h (MAX_PARTITIONS): New definition.
1085 (class fhandler_dev_floppy): Add partitions array member. Add close
1087 * fhandler_floppy.cc (fhandler_dev_floppy::fhandler_dev_floppy): Zero
1088 out partitions array.
1089 (fhandler_dev_floppy::open): Fix "entire disk" condition for call to
1090 DeviceIoControl (FSCTL_ALLOW_EXTENDED_DASD_IO).
1091 When opening disks for writing, call DeviceIoControl (FSCTL_LOCK_VOLUME)
1092 on all affected disk partitions starting with Vista.
1093 (fhandler_dev_floppy::close): New method.
1094 (fhandler_dev_floppy::dup): Duplicate handles in partitions, if any.
1095 * wincap.h (wincaps::has_restricted_raw_disk_access): New element.
1096 * wincap.cc: Implement above element throughout.
1098 2011-01-11 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
1100 * termios.cc (cfgetospeed, cfgetispeed): Constify argument per POSIX.
1101 * include/sys/termios.h (cfgetospeed, cfgetispeed): Declare functions.
1102 Move macros after declarations and make conditional on !__cplusplus.
1104 2011-01-11 Corinna Vinschen <corinna@vinschen.de>
1106 * cygtls.cc (_cygtls::init_thread): Call _REENT_INIT_PTR. Drop setting
1107 current locale and calling srand48.
1109 2011-01-02 Christopher Faylor <me+cygwin@cgf.cx>
1111 * ChangeLog-2010: Create from ChangeLog.
1112 * ChangeLog: Start fresh.