]> sourceware.org Git - newlib-cygwin.git/blob - winsup/cygwin/ChangeLog
Eliminate trailing whitespace in some files.
[newlib-cygwin.git] / winsup / cygwin / ChangeLog
1 2011-05-02 Christopher Faylor <me.cygwin2011@cgf.cx>
2
3 * dll_init.cc (dll_list::alloc): Reset 'p' in forked process.
4
5 * select.cc (select_stuff::wait): Move cleanup() closer to WFMO to
6 minimize unavoidable (?) race.
7
8 2011-05-02 Corinna Vinschen <corinna@vinschen.de>
9
10 * fhandler_serial.cc (fhandler_serial::raw_read): Add restartability
11 after a signal. Add cancelability.
12 (fhandler_serial::raw_write): Wait for write to succeed if O_NONBLOCK
13 is not set. Add signal handling and cancelability.
14
15 2011-05-01 Corinna Vinschen <corinna@vinschen.de>
16
17 * fhandler_windows.cc (fhandler_windows::read): Use
18 pthread::get_cancel_event to fetch thread's cancel event.
19 * flock.cc (lf_setlock): Ditto.
20 * posix_ipc.cc (ipc_cond_timedwait): Ditto.
21 * thread.cc (pthread::get_cancel_event): New static method.
22 * thread.h (pthread::get_cancel_event): Declare.
23
24 2011-05-01 Corinna Vinschen <corinna@vinschen.de>
25
26 * libc/minires-os-if.c (get_dns_info): Remove unnecessary test for
27 existence of DnsQuery_A.
28
29 2011-05-01 Corinna Vinschen <corinna@vinschen.de>
30
31 Throughout, use user32 UNICODE functions rather than ANSI functions.
32 * autoload.cc: Convert all definitions for ANSI user32 functions to
33 definitions for the corresponding UNICODE function.
34 (SendMessageA): Remove.
35 (SendNotifyMessageW): Define.
36 * fhandler.h (fhandler_windows::is_slow): Remove.
37 * fhandler_windows.cc (fhandler_windows::write): Use SendNotifyMessageW
38 call rather than SendMessage to make function always return immediately.
39 (fhandler_windows::read): Make function interruptible and a cancellation
40 point. Handle O_NONBLOCK.
41 * select.cc (peek_serial): Don't wait for signal_arrived here.
42 * window.cc (wininfo::winthread): Call CreateWindowExW directly rather
43 than CreateWindow wrapper.
44
45 2011-05-01 Corinna Vinschen <corinna@vinschen.de>
46
47 * net.cc (fdsock): Drop setting uninterruptible_io to true.
48
49 2011-05-01 Corinna Vinschen <corinna@vinschen.de>
50
51 * fhandler.h (fhandler_socket::is_slow): Remove.
52
53 2011-04-30 Corinna Vinschen <corinna@vinschen.de>
54
55 * fcntl.cc (fcntl64): Call pthread_testcancel.
56 * fhandler_socket.cc (fhandler_socket::connect): Ditto.
57 (fhandler_socket::accept4): Ditto.
58 (fhandler_socket::recvfrom): Ditto.
59 (fhandler_socket::recvmsg): Ditto.
60 (fhandler_socket::sendto): Ditto.
61 (fhandler_socket::sendmsg): Ditto.
62 * flock.cc (lf_setlock): Allow to cancel thread running blocking
63 file lock. Try to make code more readable.
64 (lockf): Call pthread_testcancel.
65 * mmap.cc (msync): Ditto.
66 * posix_ipc.cc (ipc_cond_timedwait): Call pthread::static_cancel_self
67 rather than pthread_testcancel.
68 * select.cc (cygwin_select): Call pthread_testcancel.
69 * syscalls.cc (pread): Ditto.
70 (pwrite): Ditto.
71 (readv): Ditto.
72 (writev): Ditto.
73 (open): Ditto.
74 (close): Ditto.
75 (fsync): Ditto.
76 * termios.cc (tcdrain): Ditto.
77 * thread.cc: Align list of cancellation points with above changes.
78 Mark not-implemented functions, too.
79 (cancelable_wait): Don't set unused object indices to WAIT_FAILED
80 since that could result in wrong behaviour. Set them to the invalid
81 value WAIT_TIMEOUT + 1 instead.
82
83 2011-04-30 Corinna Vinschen <corinna@vinschen.de>
84
85 * thread.h (class pthread): Add bool member canceled.
86 * thread.cc (pthread::pthread): Initialize canceled to false.
87 (pthread::cancel): Set canceled before setting cancel_event.
88 (pthread::testcancel): Check for canceled. Only wait for cancel_event
89 if canceled is true. Explain why.
90 (pthread::_fixup_after_fork): Set canceled to false.
91
92 2011-04-29 Corinna Vinschen <corinna@vinschen.de>
93
94 * errno.cc (errmap): Sort. Map ERROR_EXE_MACHINE_TYPE_MISMATCH to
95 ENOEXEC.
96
97 2011-04-29 Corinna Vinschen <corinna@vinschen.de>
98
99 * thread.cc: Update comment listing cancellation points per POSIX.
100
101 2011-04-29 Corinna Vinschen <corinna@vinschen.de>
102
103 * advapi32.cc: Add comment.
104 (EqualSid): Remove.
105 (CopySid): Remove.
106 (AddAccessAllowedAce): Remove.
107 (AddAccessDeniedAce): Remove.
108 (MakeSelfRelativeSD): Remove.
109 * flock.cc: Replace above functions throughout with their ntdll.dll
110 equivalent.
111 * sec_acl.cc: Ditto.
112 * sec_auth.cc: Ditto.
113 * sec_helper.cc: Ditto.
114 * security.cc: Ditto.
115 * security.h: Ditto.
116 (RtlEqualSid): Declare. Explain why.
117 (RtlCopySid): Ditto.
118
119 2011-04-29 Corinna Vinschen <corinna@vinschen.de>
120
121 * advapi32.cc (AccessCheck): Remove.
122 (PrivilegeCheck): Remove.
123 (OpenThreadToken): Remove.
124 * fhandler_tty.cc: Replace above functions throughout with their
125 ntdll.dll equivalent.
126 * security.cc: Ditto.
127
128 2011-04-29 Corinna Vinschen <corinna@vinschen.de>
129
130 * ntdll.h (IsEventSignalled): New inline function.
131 * cygthread.cc (cygthread::terminate_thread): Use IsEventSignalled in
132 place of WaitForSingleObject on event with 0 timeout.
133 * fhandler.cc (fhandler_base_overlapped::has_ongoing_io): Ditto.
134 * fhandler_fifo.cc (fhandler_fifo::open_nonserver): Ditto.
135 (fhandler_fifo::wait): Ditto.
136 * fhandler_termios.cc (fhandler_termios::bg_check): Ditto.
137 * select.cc (verify_tty_slave): Ditto.
138 * thread.cc (pthread::testcancel): Ditto.
139
140 2011-04-29 Corinna Vinschen <corinna@vinschen.de>
141
142 * advapi32.cc (GetTokenInformation): Remove.
143 (SetTokenInformation): Remove.
144 * grp.cc: Replace above functions throughout with their ntdll.dll
145 equivalent.
146 * sec_auth.cc: Ditto.
147 * syscalls.cc: Ditto.
148 * uinfo.cc: Ditto.
149
150 2011-04-29 Corinna Vinschen <corinna@vinschen.de>
151
152 * posix_ipc.cc (ipc_cond_timedwait): Only wait for pthread's
153 cancel_event if thread's cancelability isn't disabled.
154
155 2011-04-28 Corinna Vinschen <corinna@vinschen.de>
156
157 * advapi32.cc (SetSecurityDescriptorDacl): Remove.
158 (SetSecurityDescriptorGroup): Remove.
159 (SetSecurityDescriptorOwner): Remove.
160 * pinfo.cc: Replace above functions throughout with their ntdll.dll
161 equivalent.
162 * sec_acl.cc: Ditto.
163 * sec_helper.cc: Ditto.
164 * security.cc: Ditto.
165
166 * sec_helper.cc (__sec_user): Remove old comment.
167
168 2011-04-28 Corinna Vinschen <corinna@vinschen.de>
169
170 * posix_ipc.cc (ipc_cond_timedwait): Also wait for pthread's
171 cancel_event, if any. Call pthread_testcancel if cancel_event has been
172 signalled.
173
174 2011-04-28 Corinna Vinschen <corinna@vinschen.de>
175
176 * posix_ipc.cc (ipc_cond_timedwait): Remove pthread_testcancel calls.
177 (_mq_send): Add pthread_testcancel call at start of function.
178 (_mq_receive): Ditto.
179
180 2011-04-28 Corinna Vinschen <corinna@vinschen.de>
181
182 * cygerrno.h (geterrno_from_nt_status): Declare.
183 * errno.cc (geterrno_from_nt_status): Define.
184 * flock.cc: Fix copyright dates.
185 * ntdll.h (enum _TIMER_TYPE): Define.
186 (PTIMER_APC_ROUTINE): Define.
187 (NtCancelTimer): Declare.
188 (NtCreateTimer): Declare.
189 (NtSetTimer): Declare.
190 * posix_ipc.cc (ipc_cond_timedwait): Rewrite to make interruptible and
191 restartable. Call pthread_testcancel in case of timeout to enable
192 pthread_cancel on waiting thread. Replace WFMO timeout with waiting
193 for a waitable timer. Explain why. Replace single call to WFMO with
194 two calls, one for the event, one for the mutex. Don't lock mutex in
195 case of error.
196 (ipc_cond_signal): Make void function.
197 (ipc_cond_close): Ditto.
198 (_mq_send): Immediately return -1 in case of error from
199 ipc_cond_timedwait.
200 (_mq_receive): Ditto.
201
202 2011-04-28 Corinna Vinschen <corinna@vinschen.de>
203
204 * advapi32.cc (GetSecurityDescriptorDacl): Remove.
205 (GetSecurityDescriptorGroup): Remove.
206 (GetSecurityDescriptorOwner): Remove.
207 * sec_acl.cc: Replace above functions throughout with their ntdll.dll
208 equivalent. Remove redundant debug output.
209 * sec_auth.cc: Ditto.
210 * security.cc: Ditto.
211 * uinfo.cc: Ditto.
212
213 2011-04-28 Corinna Vinschen <corinna@vinschen.de>
214
215 * advapi32.cc (InitializeAcl): Remove.
216 (AddAce): Remove.
217 (FindFirstFreeAce): Remove.
218 (GetAce): Remove.
219 (InitializeSecurityDescriptor): Remove.
220 (OpenProcessToken): Remove.
221 * dcrt0.cc: Replace above functions throughout with their ntdll.dll
222 equivalent.
223 * fhandler_tty.cc: Ditto.
224 * flock.cc: Ditto.
225 * pinfo.cc: Ditto. Drop unnecessary error handling.
226 * sec_acl.cc: Ditto.
227 * sec_auth.cc: Ditto.
228 * sec_helper.cc: Ditto.
229 * security.cc: Ditto.
230
231 2011-04-28 Corinna Vinschen <corinna@vinschen.de>
232
233 * advapi32.cc (InitializeSid): Remove.
234 (EqualPrefixSid): Remove.
235 (GetLengthSid): Remove.
236 (GetSidSubAuthority): Remove.
237 (GetSidSubAuthorityCount): Remove.
238 (GetSidIdentifierAuthority): Remove.
239 * fhandler_disk_file.cc: Replace above functions throughout with their
240 ntdll.dll equivalent.
241 * sec_auth.cc: Ditto.
242 * sec_helper.cc: Ditto.
243 * security.cc: Ditto.
244
245 2011-04-28 Corinna Vinschen <corinna@vinschen.de>
246
247 * advapi32.cc (AllocateLocallyUniqueId): Remove.
248 * fhandler_disk_file.cc (fhandler_base::open_fs): Replace call to
249 AllocateLocallyUniqueId with call to NtAllocateLocallyUniqueId;
250 * posix_ipc.cc (mq_open): Ditto. Drop error handling for that call.
251 (sem_open): Ditto.
252
253 2011-04-28 Corinna Vinschen <corinna@vinschen.de>
254
255 * autoload.cc (GetSecurityInfo): Remove.
256 * ntdll.h (RtlConvertToAutoInheritSecurityObject): Declare.
257 (RtlDeleteSecurityObject): Declare.
258 (RtlGetControlSecurityDescriptor): Declare.
259 (RtlLengthSecurityDescriptor): Declare.
260 * security.cc (file_mapping): New global variable.
261 (get_file_sd): Rewrite. Clean up code. Get rid of GetSecurityInfo
262 call.
263 (alloc_sd): Call RtlSetControlSecurityDescriptor to set
264 SE_DACL_PROTECTED flag.
265 (check_file_access): Remove mapping. Use file_mapping instead.
266 (check_registry_access): Rename mapping to reg_mapping.
267 * wincap.cc: Througout, drop use_get_sec_info_on_dirs,
268 * wincap.h (struct wincaps): Drop use_get_sec_info_on_dirs.
269
270 2011-04-24 Corinna Vinschen <corinna@vinschen.de>
271
272 * include/fenv.h: Add missing _FENV_H_ define.
273
274 2011-04-23 Corinna Vinschen <corinna@vinschen.de>
275
276 * registry.cc (reg_key::get_dword): Rename from get_int, use DWORD
277 rather than int type. Avoid compiler warning.
278 (reg_key::set_dword): Rename from set_int, use DWORD rather than int
279 type. Change return type to NTSTATUS.
280 (reg_key::get_string): Change return type to NTSTATUS.
281 (reg_key::set_string): Ditto.
282 * registry.h: Accommodate above changes.
283 * environ.cc (regopt): Test return value of reg_key::get_string as
284 NTSTATUS.
285 * sched.cc (sched_rr_get_interval): Change local int vars to DWORD.
286 Call reg_key::get_dword instead of reg_key::get_int.
287 * shared.cc (init_installation_root): Test return value of
288 reg_key::get_string as NTSTATUS.
289 (shared_info::heap_slop_size): Call reg_key::get_dword rather than
290 reg_key::get_int.
291 (shared_info::heap_chunk_size): Ditto.
292 * shared_info.h (CURR_SHARED_MAGIC): Update.
293 (class shared_info): Change heap_chunk and heap_slop to DWORD values.
294
295 2011-04-21 Corinna Vinschen <corinna@vinschen.de>
296
297 * cygtls.cc (_cygtls::init_thread): Drop setting locals.process_logmask.
298 * cygtls.cc (_cygtls::remove): Always free mallocated TLS storage on
299 thread exit. Drop freeing locals.process_ident.
300 * cygtls.h (struct _local_storage): Remove syslog-related members.
301 * syslog.cc (syslog_globals): New static storage for global syslog
302 settings. Use throughout instead of _my_tls.locals.
303 (openlog): Set new syslog_globals.process_ident value more carefully.
304 * tlsoffsets.h: Regenerate.
305
306 2011-04-21 Thomas Stalder <cygwinml@gmail.com>
307
308 * include/sys/poll.h: Include signal.h to get definition of sigset_t.
309
310 2011-04-20 Christopher Faylor <me.cygwin2011@cgf.cx>
311
312 * cygheap.cc (init_cygheap::close_ctty): Avoid closing console-cttys
313 since they don't use archetypes and this will just result in double
314 frees.
315 * dll_init.cc (dll_list::protect): Define.
316 (dll_list::alloc): Guard list access.
317 (dll_list::detach): Ditto.
318 * dll_init.h (dll_list::protect): Declare new muto.
319 (dll_list::guard): Define/declare function to guard list access.
320 * fhandler_termios.cc (fhandler_termios::sigflush): Avoid SEGV in
321 pathological condition of get_ttyp() == NULL.
322
323 2011-04-20 Christopher Faylor <me.cygwin2011@cgf.cx>
324
325 * select.cc (serial_cleanup): Make sure that device_specific_pipe is
326 always deleted regardless of whether it has a unique thread associated
327 with it
328 (socket_cleanup): Ditto.
329 (mailslot_cleanup): Ditto.
330
331 2011-04-20 Corinna Vinschen <corinna@vinschen.de>
332
333 * devices.h: Renumber internal devices so that FH_PROCESS is part of
334 the /proc family of virtual devices.
335 (FH_PROC_MAX_MINOR): Define.
336 * path.h (isproc_dev): Use FH_PROC_MAX_MINOR rather than FH_PROC.
337
338 2011-04-19 Peter Rosin <peda@lysator.liu.se>
339
340 * select.cc (pipe_cleanup): Make sure that device_specific_pipe is
341 always deleted regardless of whether it has a unique thread associated
342 with it.
343
344 2011-04-19 Jon TURNEY <jon.turney@dronecode.org.uk>
345
346 * thread.cc (semaphore::init): We cannot reliably infer anything from
347 the existing contents of sem, so merely warn rather than return EBUSY
348 if it looks like we are reinitialising a semaphore.
349
350 2011-04-19 Corinna Vinschen <corinna@vinschen.de>
351
352 * autoload.cc (GetConsoleWindow): Drop.
353 (GetSystemWindowsDirectoryW): Drop.
354 * fhandler_console.cc (beep): Call GetSystemWindowsDirectoryW instead of
355 GetWindowsDirectoryW.
356 * uinfo.cc (cygheap_user::env_systemroot): Call
357 GetSystemWindowsDirectoryW and convert to multibyte on the fly.
358 * winlean.h (GetWindowsDirectoryW): Redefine to something invalid.
359 Explain why.
360
361 2011-04-19 Corinna Vinschen <corinna@vinschen.de>
362
363 * Makefile.in (DLL_IMPORTS): Drop advapi32.dll.
364 * autoload.cc: Enable autoloading advapi32 functions.
365 * environ.cc (regopt): Use wide char arguments in reg_key functions.
366 * fhandler_console.cc (beep): Ditto. Use WCHAR throughout.
367 * registry.cc (reg_key): Rewrite reg_key class to use native NT registry
368 functions. Use WCHAR string parameters throughout. Use PCWSTR rather
369 than const WCHAR. Drop multibyte char functionality. Drop unused
370 methods.
371 (get_registry_hive_path): Use RtlQueryRegistryValues to fetch path from
372 registry.
373 (load_registry_hive): Drop useless check for user hive being available.
374 Load hive using NtLoadKey.
375 * registry.h: Accommodate above changes.
376 * sched.cc (sched_rr_get_interval): Use wide char arguments in reg_key
377 functions.
378 * shared.cc (init_installation_root): Ditto.
379 (shared_info::init_obcaseinsensitive): Use RtlQueryRegistryValues to
380 fetch obcaseinsensitive value.
381 (shared_info::heap_slop_size): Use wide char arguments in reg_key
382 functions.
383 (shared_info::heap_chunk_size): Ditto.
384 * syscalls.cc (gethostid): Ditto.
385 * winsup.h (__WIDE): Define.
386 (_WIDE): Define.
387 * libc/minires-os-if.c (get_registry_dns_items): Don't fetch values
388 from registry. Just extract them from given UNICODE_STRING parameter.
389 (get_registry_dns): Fetch all registry values at once using
390 RtlQueryRegistryValues.
391
392 2011-04-19 Corinna Vinschen <corinna@vinschen.de>
393
394 * net.cc (get_ipv4fromreg_ipcnt): Rearrange to fetch all registry
395 values at once using RtlQueryRegistryValues.
396 (get_ipv4fromreg): Ditto.
397
398 2011-04-19 Corinna Vinschen <corinna@vinschen.de>
399
400 * fhandler_registry.cc (fhandler_registry::fstat): Use RegQueryInfoKeyW.
401
402 2011-04-19 Corinna Vinschen <corinna@vinschen.de>
403
404 * fhandler_proc.cc (read_value): Remove definition.
405 (print): Simplify.
406 (format_proc_cpuinfo): Drop useless call to GetSystemInfo. Rearrange
407 to use Rtl registry functions. Rename dwOldThreadAffinityMask to
408 orig_affinity_mask.
409
410 2011-04-18 Corinna Vinschen <corinna@vinschen.de>
411
412 * localtime.cc (tzload): Don't change global timezone information
413 when called from gmtime or gmtime_r.
414 (tzparse): Ditto.
415
416 2011-04-18 Corinna Vinschen <corinna@vinschen.de>
417
418 * cygtls.cc (_cygtls::remove): Always close sockevt handle.
419
420 2011-04-18 Corinna Vinschen <corinna@vinschen.de>
421
422 * cygwin.din (ppoll): Export.
423 * poll.cc (ppoll): Implement.
424 * posix.sgml (std-gnu): Add ppoll.
425 * include/cygwin/version.h: Bump API minor number.
426 * include/sys/poll.h (ppoll): Declare.
427
428 2011-04-18 Corinna Vinschen <corinna@vinschen.de>
429
430 * fhandler_socket.cc (fhandler_socket::evaluate_events): Handle the
431 FD_CLOSE event specially when called from accept. Explain why.
432 (fhandler_socket::shutdown): Fake success on not-connected socket and
433 trigger socket event if the read side of a socket is affected. Explain
434 why.
435 * poll.cc (poll): Check for saw_shutdown_read on sockets to generate
436 POLLHUP as well.
437
438 2011-04-18 Corinna Vinschen <corinna@vinschen.de>
439
440 * Fix various copyrights.
441
442 2011-04-17 Christopher Faylor <me.cygwin2011@cgf.cx>
443
444 * signal.cc (_pinfo::kill): Set this_process_state when process
445 exists.
446
447 2011-04-17 Christopher Faylor <me.cygwin2011@cgf.cx>
448
449 * signal.cc (_pinfo::kill): Return 0 when attempting to test for
450 existence of an existed process which has not yet been reaped.
451
452 2011-04-17 Christopher Faylor <me.cygwin2011@cgf.cx>
453
454 * cygheap.h (init_cygheap::ctty): Use base class so that console can
455 join in the fun.
456 * dtable.cc (dtable::stdio_init): Remove special-case call to
457 set_console_ctty ().
458 * exceptions.cc (sigpacket::process): Conditionally flush terminal
459 input on certain signals.
460 * fhandler.h (fhandler_console::get_tty_stuff): Make non-static.
461 (fhandler_termios::get_ttyp): Move here.
462 (fhandler_termios::sigflush): Declare.
463 (fhandler_tty_common::get_ttyp): Delete.
464 * fhandler_console.cc (fhandler_console::get_tty_stuff): Pass this as
465 "arch" argument.
466 (set_console_ctty): Delete.
467 (tty_list::get_tty): Just return pointer to shared console region,
468 delaying get_tty_stuff until open().
469 (fhandler_console::init): Treat NULL handle as signifying that console
470 should be opened with O_NOCTTY flag. Rename handle argument to the
471 more common 'h'.
472 * fhandler_termios.cc (fhandler_termios::sigflush): Define.
473 * fhandler_tty.cc (handler_tty_master::init_console): Pass NULL as
474 first argument to fhandler_console::init.
475 * pinfo.cc (_pinfo::set_ctty): Change third parameter to
476 fhandler_termios *. Add extra debugging.
477 * pinfo.h (_pinfo::set_ctty): Change third parameter to
478 fhandler_termios *.
479
480 * sigproc.cc (handle_sigsuspend): Don't special-case non-main threads.
481
482 2011-04-15 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
483
484 * thread.cc (pthread_setschedprio): New function.
485 * include/pthread.h (pthread_setschedprio): Declare.
486 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
487 * cygwin.din (pthread_setschedprio): Export.
488 * posix.sgml (std-notimpl) Move pthread_setschedprio from here...
489 (std-susv4) ...to here.
490
491 2011-04-10 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
492
493 * fhandler_proc.cc (proc_tab): Add /proc/swaps virtual file.
494 (format_proc_swaps): New function.
495
496 2011-04-06 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
497
498 * Makefile.in: Move srcdir definition before others which uses it.
499
500 2011-04-06 Jon TURNEY <jon.turney@dronecode.org.uk>
501
502 * dll_init.cc (reserve_at, release_at): New functions.
503 (load_after_fork): If the DLL was loaded higher than the required
504 address, assume that it loaded at it's base address and also reserve
505 memory there to force it to be relocated.
506
507 2011-04-04 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
508
509 * include/cygwin/types.h: Move #include <sys/sysmacros.h> to
510 end of header so that it gets the dev_t typedef.
511 * include/sys/sysmacros.h (gnu_dev_major, gnu_dev_minor,
512 gnu_dev_makedev): Prototype and define as inline functions.
513 (major, minor, makedev): Redefine in terms of gnu_dev_*.
514
515 2011-04-04 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
516
517 * include/cygwin/types.h: Move multiple inclusion guards to
518 beginning and end of header.
519
520 2011-04-04 Christopher Faylor <me.cygwin2011@cgf.cx>
521
522 * Makefile.in: Move Makefile.common include earlier to fix problems
523 with relative ${srcdir} path which confuses make.
524
525 2011-04-04 Corinna Vinschen <corinna@vinschen.de>
526
527 Drop NT4 support.
528 * autoload.cc (DnsQuery_A): Fatal if not available.
529 (DnsRecordListFree): Ditto.
530 (DsGetDcNameW): Ditto.
531 (NetGetAnyDCName): Remove.
532 (NetGetDCName): Remove.
533 (EnumProcessModules): Fatal if not available.
534 (GetModuleFileNameExW): Ditto.
535 (GetModuleInformation): Ditto.
536 (GetProcessMemoryInfo): Ditto.
537 (QueryWorkingSet): Ditto.
538 (LsaRegisterLogonProcess): Ditto.
539 * fenv.cc (_feinitialise): Drop supports_sse condition.
540 * fhandler_disk_file.cc (path_conv::isgood_inode): Fix comment.
541 (fhandler_base::fstat_by_name): Drop has_fileid_dirinfo condition.
542 (fhandler_disk_file::opendir): Ditto.
543 * fhandler_netdrive.cc (fhandler_netdrive::readdir): Fix comment.
544 * fhandler_proc.cc (format_proc_partitions): Drop NT4-only code.
545 * fhandler_process.cc (get_process_state): Ditto.
546 * kernel32.cc (GetWindowsDirectoryW): Remove.
547 (GetWindowsDirectoryA): Remove.
548 * miscfuncs.cc (nice_to_winprio): Drop NT4-only code.
549 * mount.cc (fs_info::update): Fix comments.
550 * net.cc (get_2k_ifs): Drop NT4-only code.
551 * sec_auth.cc (get_logon_server): Ditto.
552 (lsaauth): Drop NT4-specific error handling.
553 * security.cc (alloc_sd): Set SE_DACL_PROTECTED unconditionally.
554 * select.cc (select_stuff::wait): Always use MWMO_INPUTAVAILABLE.
555 (peek_windows): Drop NT4-only condition in call to PeekMessage.
556 * syscalls.cc (gethostid): Remove NT4-only workaround.
557 * wincap.cc: Througout, drop has_dacl_protect,
558 has_broken_if_oper_status, has_process_io_counters,
559 has_terminal_services, has_extended_priority_class, has_guid_volumes,
560 has_fileid_dirinfo, has_mwmo_inputavailable and supports_sse from
561 wincaps.
562 (wincap_nt4sp4): Remove.
563 (wincap_minimal): Set to wincap_2000.
564 (wincapc::init): Rely on availability of OSVERSIONINFOEX structure.
565 Treat error from GetVersionEx as fatal. Treat NT4 as fatal.
566 * wincap.h (struct wincaps): Drop has_dacl_protect,
567 has_broken_if_oper_status, has_process_io_counters,
568 has_terminal_services, has_extended_priority_class, has_guid_volumes,
569 has_fileid_dirinfo, has_mwmo_inputavailable and supports_sse flags
570 and methods.
571 * winlean.h (GetWindowsDirectoryW) Define as GetSystemWindowsDirectoryW.
572 (GetWindowsDirectoryA): Define as GetSystemWindowsDirectoryA.
573
574 2011-04-04 Corinna Vinschen <corinna@vinschen.de>
575
576 * dtable.cc (dtable::init_std_file_from_handle): Fix a comment to
577 reflect the current state.
578
579 2011-04-04 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
580
581 * Makefile.in (fhandler_proc_CFLAGS): Define USERNAME, HOSTNAME,
582 and GCC_VERSION.
583 * fhandler_proc.cc (format_proc_version): Add build machine and GCC
584 version information as on Linux.
585
586 2011-04-04 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
587 Corinna Vinschen <corinna@vinschen.de>
588
589 * devices.h (fh_devices): Define FH_PROC_MIN_MINOR.
590 Reorder major-0 devices so that all /proc directories fall
591 between FH_PROC and FH_PROC_MIN_MINOR.
592 * path.h (isproc_dev): Redefine accordingly.
593
594 2011-04-04 Corinna Vinschen <corinna@vinschen.de>
595
596 * cygserver_setpwd.h (setlsapwd): Add username parameter to declaration.
597 * external.cc (cygwin_internal): In the CW_SET_PRIV_KEY case, fetch
598 additional username parameter.
599 * setlsapwd.cc (setlsapwd): Add username parameter. Allow admin to
600 set the hidden password for other users.
601
602 2011-04-04 Corinna Vinschen <corinna@vinschen.de>
603
604 * sec_auth.cc (get_user_groups): Mark well-known groups as well-known.
605 (get_user_local_groups): Ditto.
606 (verify_token): Drop useless label.
607 * sec_helper.cc (cygsid::get_sid): Check for well-known SID if
608 well_known isn't set.
609 * security.h (well_known_sid_type): New inline function.
610
611 2011-04-02 Corinna Vinschen <corinna@vinschen.de>
612
613 * autoload.cc (FindFirstVolumeA): Remove.
614 (FindNextVolumeA): Remove.
615 (FindVolumeClose): Remove.
616 (GetVolumeNameForVolumeMountPointA): Remove.
617 * ntdll.h (NtFlushBuffersFile): Declare.
618 * syscalls.cc (sync_worker): Rewrite using native NT functions.
619 (sync): Ditto.
620
621 2011-04-02 Corinna Vinschen <corinna@vinschen.de>
622
623 * fhandler_proc.cc (format_proc_partitions): Express length in WCHAR
624 size.
625
626 2011-04-02 Corinna Vinschen <corinna@vinschen.de>
627
628 * autoload.cc (GetExtendedTcpTable): Remove.
629 (GetTcpTable): Remove.
630 (CharNextExA): Remove.
631 (FindWindowA): Remove.
632 (ShowWindowAsync): Remove.
633 * dcrt0.cc (disable_dep): Remove unused function.
634 (dll_crt0_0): Drop comment babbling about TS & DEP.
635 * fhandler_socket.cc (address_in_use): Remove unused function.
636 * wincap.cc: Throughout, drop ts_has_dep_problem from wincaps.
637 (wincapc::init): Drop code setting ts_has_dep_problem flag.
638 * wincap.h (struct wincaps): Drop ts_has_dep_problem flags and method.
639
640 2011-04-01 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
641
642 Implement /proc/sysvipc/*
643 * devices.in (dev_procsysvipc_storage): Add.
644 * devices.cc: Regenerate.
645 * devices.h (fh_devices): Add FH_PROCSYSVIPC.
646 * dtable.cc (build_fh_pc): Add case FH_PROCSYSVIPC.
647 * fhandler.h (class fhandler_procsysvipc): Declare.
648 (fhandler_union): Add __procsysvipc.
649 * fhandler_proc.cc (proc_tab): Add sysvipc virt_directory.
650 * fhandler_procsysvipc.cc: New file.
651 * Makefile.in (DLL_OFILES): Add fhandler_procsysvipc.o.
652 * path.h (isproc_dev): Add FH_PROCSYSVIPC to conditional.
653
654 2011-04-01 Corinna Vinschen <corinna@vinschen.de>
655
656 * Makefile.in (DLL_OFILES): Add avapi32.o.
657 * advapi32.cc: New file.
658 * autoload.cc: Add block of remaining advapi32 functions used by
659 Cygwin. Keep commented out. Explain why.
660
661 2011-04-01 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
662
663 * fhandler_proc.cc (format_proc_loadavg): Add running/total
664 processes as fourth component of output.
665 * fhandler_process.cc (get_process_state): Make non-static.
666 Add FIXME about generating an 'O' flag.
667
668 2011-04-01 Corinna Vinschen <corinna@vinschen.de>
669
670 * fhandler_random.cc (fhandler_dev_random::crypt_gen_random):
671 Use CryptAcquireContextW.
672 * ntdll.h (STATUS_PROCEDURE_NOT_FOUND): Define.
673 * sec_auth.cc (open_local_policy): Rename NTSTATUS variable ret to
674 status. Drop usage of LsaNtStatusToWinError.
675 (verify_token): Call NtQuerySecurityObject instead of
676 GetKernelObjectSecurity.
677 (create_token): Rename NTSTATUS variable ret to status. Rename ret2 to
678 sub_status. Drop usage of LsaNtStatusToWinError. In case LsaLogonUser
679 fails, report the sub_status as well.
680
681 2011-04-01 Corinna Vinschen <corinna@vinschen.de>
682
683 * libc/strptime.c: Remove misleading comment.
684
685 2011-03-31 Corinna Vinschen <corinna@vinschen.de>
686
687 * ntdll.h: Allow usage from plain C code.
688 (FSCTL_PIPE_IMPERSONATE): Define.
689 (enum _THREAD_INFORMATION_CLASS): Define.
690 (RTL_QUERY_REGISTRY_xxx): Define.
691 (RTL_REGISTRY_xxx): Define.
692 (PRTL_QUERY_REGISTRY_ROUTINE): Define.
693 (struct _RTL_QUERY_REGISTRY_TABLE): Define.
694 (enum _KEY_VALUE_INFORMATION_CLASS): Define.
695 (struct _KEY_VALUE_PARTIAL_INFORMATION): Define.
696 (NtAccessCheck): Declare.
697 (NtAllocateLocallyUniqueId): Declare.
698 (NtCreateKey): Declare.
699 (NtDuplicateToken): Declare.
700 (NtLoadKey): Declare.
701 (NtOpenKey): Declare.
702 (NtOpenProcessToken): Declare.
703 (NtOpenThreadToken): Declare.
704 (NtPrivilegeCheck): Declare.
705 (NtQueryInformationToken): Declare.
706 (NtQueryValueKey): Declare.
707 (NtSetInformationThread): Declare.
708 (NtSetInformationToken): Declare.
709 (NtSetValueKey): Declare.
710 (RtlAbsoluteToSelfRelativeSD): Declare.
711 (RtlAddAccessAllowedAce): Declare.
712 (RtlAddAccessDeniedAce): Declare.
713 (RtlAddAce): Declare.
714 (RtlCheckRegistryKey): Declare.
715 (RtlCopySid): Declare.
716 (RtlCreateAcl): Declare.
717 (RtlCreateRegistryKey): Declare.
718 (RtlCreateSecurityDescriptor): Declare.
719 (RtlEqualPrefixSid): Declare.
720 (RtlEqualSid): Declare.
721 (RtlFirstFreeAce): Declare.
722 (RtlGetAce): Declare.
723 (RtlGetDaclSecurityDescriptor): Declare.
724 (RtlGetGroupSecurityDescriptor): Declare.
725 (RtlGetOwnerSecurityDescriptor): Declare.
726 (RtlIdentifierAuthoritySid): Declare.
727 (RtlInitializeSid): Declare.
728 (RtlLengthSid): Declare.
729 (RtlQueryRegistryValues): Declare.
730 (RtlSetControlSecurityDescriptor): Declare.
731 (RtlSetDaclSecurityDescriptor): Declare.
732 (RtlSetGroupSecurityDescriptor): Declare.
733 (RtlSetOwnerSecurityDescriptor): Declare.
734 (RtlSubAuthorityCountSid): Declare.
735 (RtlSubAuthoritySid): Declare.
736 (RtlWriteRegistryValue): Declare.
737
738 2011-03-31 Corinna Vinschen <corinna@vinschen.de>
739
740 * uinfo.cc (cygheap_user::init): Don't call GetUserName. Fetch username
741 from Windows environment instead. Explain why.
742 (cygheap_user::env_domain): Use MAX_DOMAIN_NAME_LEN rather than DNLEN
743 to specify the size of the domain name buffer.
744
745 2011-03-30 Corinna Vinschen <corinna@vinschen.de>
746
747 * hires.h: Fix copyright.
748 * times.cc: Ditto.
749 (FACTOR): Add comment.
750 (NSPERSEC): Ditto.
751 (JITTER): New definition. Comment.
752 (systime_ns): Avoid gratuitous copying of the value returned by
753 GetSystemTimeAsFileTime.
754 (corelocaltime, localtime, gmtime): Remove very old, unused code block.
755 (cygwin_tzset): Remove.
756 (hires_ms::timeGetTime_ns): Add missing semicolon in comment.
757 (hires_ms::nsecs): Redefine check for difference between internal
758 timer value and system time.
759
760 2011-03-30 Corinna Vinschen <corinna@vinschen.de>
761
762 * times.cc (hires_ms::resolution): Make sure resolution is never 0.
763 (clock_setres): Ditto.
764
765 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
766
767 * cygtls.h (struct _local_storage): Redefine process_ident as wchar_t
768 pointer.
769 * syslog.cc (CYGWIN_LOG_NAME): Convert to wide char constant.
770 (openlog): Convert incoming ident string to wide char. Fix formatting.
771 (vsyslog): Print ident string as wide char string. Convert message
772 string to wide char and call UNICODE Win32 Event functions to make sure
773 to use correct codeset.
774 * tlsoffset.h: Regenerate.
775
776 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
777
778 * fhandler_socket.cc (get_inet_addr): Make externally available.
779 * autoload.cc (GetUdpTable): Define.
780 * syslog.cc (connect_syslogd): Use get_inet_addr rather than _stat64
781 to check for local socket file. Create socket with type returned by
782 get_inet_addr. If connect on UDP socket works, test if there's
783 really a listening peer, otherwise fall back to Windows event log.
784 (try_connect_syslogd): Use syslogd_inited flag to check if syslogd
785 is available.
786
787 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
788
789 * uinfo.cc (cygheap_user::env_domain): Use LookupAccountSidW and
790 convert user and domain to multibyte strings to make sure to use
791 correct codeset.
792
793 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
794
795 * autoload.cc (UuidCreate): Remove.
796 (UuidCreateSequential): Remove.
797 * passwd.cc (internal_getpwsid): Avoid a strict-aliasing compiler
798 error with gcc 4.5.1.
799 * fhandler_floppy.cc (fhandler_dev_floppy::get_drive_info): Ditto.
800 * ntdll.h (NtAllocateUuids): Declare.
801 * syscalls.cc (gethostid): Use NtAllocateUuids function rather than
802 UuidCreateSequential/UuidCreate to get rid of rpcrt4 dependency.
803
804 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
805
806 * cygwin.din (pthread_spin_destroy): Export.
807 (pthread_spin_init): Export.
808 (pthread_spin_lock): Export.
809 (pthread_spin_trylock): Export.
810 (pthread_spin_unlock): Export.
811 * posix.sgml (std-susv4): Add pthread_spin_destroy, pthread_spin_init,
812 pthread_spin_lock, pthread_spin_trylock, pthread_spin_unlock.
813 (std-notimpl): Remove pthread_spin_[...].
814 * pthread.cc (pthread_spin_init): New function.
815 * thread.cc (pthread_spinlock::is_good_object): New function.
816 (pthread_mutex::pthread_mutex): Rearrange initializers to accommodate
817 protected data in pthread_mutex.
818 (pthread_spinlock::pthread_spinlock): New constructor.
819 (pthread_spinlock::lock): New method.
820 (pthread_spinlock::unlock): New method.
821 (pthread_spinlock::init): New method.
822 (pthread_spin_lock): New function.
823 (pthread_spin_trylock): New function.
824 (pthread_spin_unlock): New function.
825 (pthread_spin_destroy): New function.
826 * thread.h (PTHREAD_SPINLOCK_MAGIC): Define.
827 (class pthread_mutex): Change access level of members shared with
828 derived classes to protected.
829 (pthread_mutex::set_shared): New protected method.
830 (class pthread_spinlock): New class, derived class of pthread_mutex.
831 * include/pthread.h (pthread_spin_destroy): Declare.
832 (pthread_spin_init): Declare.
833 (pthread_spin_lock): Declare.
834 (pthread_spin_trylock): Declare.
835 (pthread_spin_unlock): Declare.
836 * include/cygwin/types.h (pthread_spinlock_t): New typedef.
837 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
838
839 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
840
841 * net.cc (SIO_BASE_HANDLE): Define.
842 (fdsock): If we got an LSP handle, try to create a copy of the base
843 handle instead. Change comment to explain.
844
845 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
846
847 * include/cygwin/version.h: Bump CYGWIN_VERSION_DLL_MINOR to 10.
848
849 2011-03-29 Corinna Vinschen <corinna@vinschen.de>
850
851 * autoload.cc (winmm): Remove time functions. Don't treat
852 unloadable wave functions as fatal.
853 * hires.h (hires_ms::timeGetTime_ns): New private method.
854 (hires_ms::dmsecs): Call timeGetTime_ns here.
855 * ntdll.h (struct _KSYSTEM_TIME): Define.
856 (KUSER_SHARED_DATA): Redefine to allow access to InterruptTime.
857 (SharedUserData): Define here.
858 (NtQueryTimerResolution): Declare.
859 (NtSetTimerResolution): Declare.
860 * path.cc (SharedUserData): Move to ntdll.h.
861 * times.cc (hires_ms::timeGetTime_ns): New private method.
862 Use throughout instead of timeGetTime. Document entire functionality
863 of timeGetTime in case we need it.
864 (hires_ms::resolution): Try a call to NtQueryTimerResolution
865 to fetch current period. Fall back to heuristic if that fails.
866 Cast to DWORD in assignments to minperiod.
867 (clock_setres): Align period to possible values per a call to
868 NtQueryTimerResolution. Explain why. Replace calls to timeBeginPeriod
869 and timeEndPeriod with underlying call to NtSetTimerResolution. Use
870 status code from NtSetTimerResolution to compute errno.
871 Convert period to ULONGLONG and store 100ns value to simplify code.
872
873 2011-03-29 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
874 Corinna Vinschen <corinna@vinschen.de>
875
876 * include/sys/xattr.h: New file.
877
878 2011-03-28 Jon TURNEY <jon.turney@dronecode.org.uk>
879
880 * thread.cc (semaphore::init, destroy, close): Standards conformance
881 fix. On a failure, return -1 and set errno.
882 * thread.h (semaphore::terminate): Save errno since semaphore::close()
883 may now modify it.
884
885 2011-03-27 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
886
887 * cygwin.din (strchrnul): Export.
888 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
889 * posix.sgml (std-gnu): Add strchrnul.
890
891 2011-03-27 Christopher Faylor <me.cygwin2011@cgf.cx>
892
893 * dll_init.cc (dll::init): Accommodate ill-behaved dlls who don't fill
894 out p.envptr.
895
896 2011-03-25 Corinna Vinschen <corinna@vinschen.de>
897
898 * mmap.cc (mmap64): Add a cheat to let a certain autoconf test succeed
899 on 64 bit systems. Explain why.
900
901 2011-03-23 Christopher Faylor <me.cygwin2011@cgf.cx>
902
903 * wincap.cc (wincap_2003): Set use_dont_resolve_hack to true.
904
905 2011-03-23 Christopher Faylor <me.cygwin2011@cgf.cx>
906
907 * autoload.cc (dll_load): Change error message to make it clear if a
908 newer DLL is being run.
909
910 2011-03-20 Corinna Vinschen <corinna@vinschen.de>
911
912 * fenv.cc (_feinitialise): Don't use SSE instructions on systems not
913 supporting them.
914 * wincap.h (wincaps::supports_sse): New element.
915 * wincap.cc: Implement above element throughout.
916
917 2011-03-18 Corinna Vinschen <corinna@vinschen.de>
918
919 * cygwin.sc: Raise default cygheap size to 2 Megs.
920
921 2011-03-18 Christopher Faylor <me.cygwin2011@cgf.cx>
922
923 * fhandler.h (DEFAULT_PIPEBUFSIZE): Reset to 64K.
924
925 2011-03-18 Corinna Vinschen <corinna@vinschen.de>
926
927 * mmap.cc (mmap_record::alloc_fh): Initialize name strings in fdev to
928 empty strings or suffer a SEGV. Drop second parameter in call to
929 build_fh_dev.
930
931 2011-03-18 Corinna Vinschen <corinna@vinschen.de>
932
933 * mmap.cc (class mmap_record): Pack 4 byte-aligned. Convert member dev
934 to plain int.
935 (mmap_record::alloc_fh): Create temporary device from dev and use in
936 call to build_fh_dev.
937
938 2011-03-18 Corinna Vinschen <corinna@vinschen.de>
939
940 * mmap.cc (mmap_record::page_map): Define as variable array rather than
941 as pointer.
942 (mmap_record::alloc_page_map): Remove.
943 (mmap_record::free_page_map): Remove.
944 (mmap_record::init_page_map): New method.
945 (mmap_record::add_record): Take mmap_record parameter by reference
946 rather than by value.
947 (mmap_record::map_pages): Fix comment.
948 (mmap_list::add_record): Allocate space for mmap_record including the
949 page_map in a single ccalloc call. Call init_page_map afterwards.
950 (mmap_list::del_record): Remove call to mmap_record::free_page_map.
951
952 2011-03-16 Corinna Vinschen <corinna@vinschen.de>
953
954 * crt0.c (mainCRTStartup): Move call to _feinitialise from here...
955 * dcrt0.cc (_dll_crt0): ...to here.
956
957 2011-03-16 Corinna Vinschen <corinna@vinschen.de>
958
959 * winver.rc: Fix copyright dates.
960
961 2011-03-14 Corinna Vinschen <corinna@vinschen.de>
962
963 * fhandler_disk_file.cc (fhandler_base::fstat_by_handle): Only use
964 file id as inode number if it masters the isgood_inode check.
965
966 2011-03-13 Christopher Faylor <me.cygwin2011@cgf.cx>
967
968 * fhandler.cc (fhandler_base_overlapped::wait_overlapped): Remove
969 special treatment for ERROR_NO_SYSTEM_RESOURCES. Cancel I/O and reset
970 the overlapped handle on error.
971 (fhandler_base_overlapped::write_overlapped): Limit writes to
972 max_atomic_write bytes in blocking case. Incorporate code from
973 now-defunct write_overlapped_fallback. Fix serious oversight where ptr
974 was not advanced as buffer was written.
975 (fhandler_base_overlapped::write_overlapped_fallback): Eliminate.
976 * fhandler.h (fhandler_base_overlapped::write_overlapped_fallback):
977 Ditto for declaration.
978 (DEFAULT_PIPEBUFSIZE): Lower size to slightly less than documented
979 worst-case atomic write size.
980 (fhandler_overlapped::wait_return): Remove unused element.
981
982 2011-03-09 Christopher Faylor <me.cygwin2011@cgf.cx>
983
984 * fhandler.cc (fhandler_base_overlapped::wait_overlapped): Handle
985 overlapped_fallback error condition like other error conditions. Set
986 res carefully and specifically for each condition rather than resorting
987 to a default.
988 (fhandler_base_overlapped::write_overlapped): Preserve errno in
989 overlapped_fallback condition. Correct write_overlapped_fallback to
990 avoid inappropriate looping.
991 (fhandler_base_overlapped::write_overlapped_fallback): Add some more
992 comments.
993
994 2011-03-09 Christopher Faylor <me.cygwin2011@cgf.cx>
995
996 * fhandler.cc (fhandler_base_overlapped::write_overlapp): Oops!
997 Accommodate change in arguments to wait_overlapped.
998
999 2011-03-09 Christopher Faylor <me+cygwin@cgf.cx>
1000
1001 * errno.cc (errmap): Change mapping of NO_SYSTEM_RESOURCES to EFBIG.
1002 * fhandler.cc (MAX_OVERLAPPED_WRITE_LEN): New constant.
1003 (MIN_OVERLAPPED_WRITE_LEN): Ditto.
1004 (fhandler_base_overlapped::close): Accommodate change in arguments to
1005 wait_overlapped.
1006 (fhandler_base_overlapped::setup_overlapped): Add __stdcall and regparm
1007 modifiers.
1008 (fhandler_base_overlapped::destroy_overlapped): Ditto.
1009 (fhandler_base_overlapped::has_ongoing_io): Ditto.
1010 (fhandler_base_overlapped::wait_overlapped): Modify to return an enum
1011 returning various states. Accept nonblocking parameter.
1012 (fhandler_base_overlapped::read_overlapped): Add __stdcall and regparm
1013 modifiers. Rework to attempt to be smarter about reacting to states
1014 returned by wait_overlapped.
1015 (fhandler_base_overlapped::write_overlapped): Ditto. Add fallback
1016 option for when wait_overlapped detects that smaller chunks must be
1017 written.
1018 (fhandler_base_overlapped::write_overlapped_fallback): Ditto.
1019 * fhandler.h (DEFAULT_PIPEBUFSIZE): Move definition here from pipe.cc.
1020 (fhandler_base::has_ongoing_io): Define with __stdcall and regparm
1021 modifiers.
1022 (fhandler_base_overlapped::wait_return): New enum.
1023 (fhandler_base_overlapped::max_atomic_write): New variable.
1024 (fhandler_base_overlapped:: wait_overlapped): Accommodate changes
1025 mentioned above to arguments and modifiers.
1026 (fhandler_base_overlapped::setup_overlapped): Ditto for modifiers.
1027 (fhandler_base_overlapped::read_overlapped): Ditto.
1028 (fhandler_base_overlapped::write_overlapped): Ditto.
1029 (fhandler_base_overlapped::destroy_overlapped): Ditto.
1030 (fhandler_base_overlapped::has_ongoing_io): Ditto.
1031 (fhandler_base_overlapped::fhandler_base_overlapped): Zero
1032 max_atomic_write.
1033 * fhandler_fifo.cc (fhandler_fifo::fhandler_fifo): Set max_atomic_write
1034 to the size of the DEFAULT_PIPEBUFSIZE.
1035 (fhandler_fifo::wait): Accommodate change in arguments to
1036 wait_overlapped.
1037 * pipe.cc (fhandler_pipe::fhandler_pipe): Set max_atomic_write to the
1038 size of the DEFAULT_PIPEBUFSIZE.
1039 (fhandler_pipe::create_selectable): Allow minimum size of DEFAULT_PIPEBUFSIZE.
1040 (DEFAULT_PIPEBUFSIZE): Delete here, move to fhandler.h.
1041
1042 2011-03-08 Corinna Vinschen <corinna@vinschen.de>
1043
1044 * security.cc: Fix copyright dates.
1045
1046 2011-03-08 Corinna Vinschen <corinna@vinschen.de>
1047
1048 * fhandler.cc (fhandler_base::open): When creating a file on a
1049 filesystem supporting ACLs, create the file with WRITE_DAC access.
1050 Explain why.
1051 * fhandler_disk_file.cc (fhandler_disk_file::mkdir): Ditto for
1052 directories.
1053 * fhandler_socket.cc (fhandler_socket::bind): Ditto for sockets.
1054 * path.cc (symlink_worker): Ditto for symlinks.
1055 * security.cc (get_file_sd): Always call GetSecurityInfo for directories
1056 on XP and Server 2003. Improve comment to explain why.
1057 (set_file_attribute): Explicitely cast mode_t value to bool in call to
1058 get_file_sd.
1059 * wincap.h (wincaps::use_get_sec_info_on_dirs): New element.
1060 * wincap.cc: Implement above element throughout.
1061
1062 2011-03-04 Corinna Vinschen <corinna@vinschen.de>
1063
1064 * fhandler_procsys.cc (fhandler_procsys::exists): Rewrite.
1065 (fhandler_procsys::fill_filebuf): Fill buffer with valid string even if
1066 reading the symlink fails.
1067
1068 2011-03-03 Corinna Vinschen <corinna@vinschen.de>
1069
1070 * posix_ipc.cc (ipc_cond_timedwait): If ipc_mutex_unlock fails, return
1071 actual error number.
1072 (_mq_send): Break loop if ipc_cond_timedwait returns with error.
1073 (_mq_receive): Ditto.
1074
1075 2011-03-03 Corinna Vinschen <corinna@vinschen.de>
1076
1077 * errno.cc (__xpg_strerror_r): Add accidentally missing condition.
1078
1079 2011-03-02 Corinna Vinschen <corinna@vinschen.de>
1080
1081 * fhandler_procsys.cc (fhandler_procsys::open): Call worker exists
1082 method, rather than wrapper.
1083
1084 2011-03-01 Christopher Faylor <me+cygwin@cgf.cx>
1085
1086 * autoload.cc (dll_load): Avoid in_forkee test since this apparently
1087 fails even when not forked.
1088
1089 2011-03-01 Christopher Faylor <me+cygwin@cgf.cx>
1090
1091 * include/cygwin/version.h: Bump CYGWIN_VERSION_DLL_MINOR to 9.
1092
1093 2011-02-28 Christopher Faylor <me+cygwin@cgf.cx>
1094
1095 * autoload.cc (dll_load): Only perform DONT_RESOLVE_DLL_REFERENCES hack
1096 on systems which need it.
1097 * wincap.cc (use_dont_resolve_hack): Set as appropriate.
1098 * wincap.h (use_dont_resolve_hack): Define.
1099
1100 2011-02-28 Christopher Faylor <me+cygwin@cgf.cx>
1101
1102 * autoload.cc (dll_load): Make inline. Clarify logic.
1103
1104 2011-02-27 Corinna Vinschen <corinna@vinschen.de>
1105
1106 * autoload.cc (dll_load): Only call LoadLibraryExW with
1107 DONT_RESOLVE_DLL_REFERENCES if a normal LoadLibrary call failed with
1108 ERROR_INVALID_ADDRESS.
1109 (LsaRegisterLogonProcess): Align comment to previous change.
1110
1111 2011-02-26 Christopher Faylor <me+cygwin@cgf.cx>
1112
1113 * autoload.cc: Use LoadDLLfuncEx3 for all winmm functions. Accommodate
1114 changes to LoadDLLprime.
1115 (LoadDLLprime): Take an extra argument indicating whether this dll
1116 needs special handling on fork. Place this information in the "handle"
1117 location.
1118 (LoadDLLfuncEx3): Eliminate "func" handling. Pass new
1119 no_resolve_on_fork argument to LoadDLLprime.
1120 (dll_load): New function.
1121 (std_dll_init): Accommodate changes to dll_info::handle. Use dll_load
1122 to load DLL in both cases where it is used.
1123
1124 2011-02-26 Corinna Vinschen <corinna@vinschen.de>
1125
1126 * autoload.cc: Make autoloaded ntdll function non-optional. Ditto for
1127 secur32 functions, except for LsaRegisterLogonProcess. Change return
1128 value to ERROR_PROC_NOT_FOUND. Explain why.
1129 * sec_auth.cc (lsaauth): Handle ERROR_PROC_NOT_FOUND from call to
1130 LsaRegisterLogonProcess when generating the errno value.
1131
1132 2011-02-22 Corinna Vinschen <corinna@vinschen.de>
1133
1134 * dcrt0.cc: Fix copyright dates.
1135 * winsup.h: Ditto.
1136 * syscalls.cc (_read): Move EXPORT_ALIAS to its rightful place.
1137
1138 2011-02-21 Christopher Faylor <me+cygwin@cgf.cx>
1139
1140 * cygwin.din: Mark __assert* and _abort as NOSIGFE.
1141
1142 2011-02-21 Corinna Vinschen <corinna@vinschen.de>
1143
1144 * fhandler_socket (fhandler_socket::readv): Call recv_internal directly,
1145 rather than recvmsg.
1146 (fhandler_socket::writev): Call send_internal directly, rather than
1147 sendmsg.
1148 * net.cc (cygwin_recv): Call fhandler_socket::recvfrom directly, rather
1149 than cygwin_recvfrom.
1150 (cygwin_send): Call fhandler_socket::sendto directly, rather than
1151 cygwin_sendto.
1152
1153 2011-02-20 Christopher Faylor <me+cygwin@cgf.cx>
1154
1155 * fhandler.cc (fhandler_base_overlapped::close): Finish any pending I/O
1156 before closing.
1157 (fhandler_base_overlapped::wait_overlapped): Defensively zero bytes
1158 read. Add more info to debugging output.
1159
1160 2011-02-18 Christopher Faylor <me+cygwin@cgf.cx>
1161
1162 * dcrt0.cc (dll_crt0_1): Add a CYGHEAP_DEBUG conditional for debugging
1163 which allocates a lot of space at startup.
1164
1165 2011-02-18 Corinna Vinschen <corinna@vinschen.de>
1166
1167 * cygwin.sc: Set alignment of .cygheap section to 64K.
1168
1169 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
1170
1171 * spawn.cc (spawn_guts): Only set PID_NOTCYGWIN in _P_OVERLAY mode.
1172 Drop flag if creating new process failed.
1173
1174 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
1175
1176 * Throughout fix copyright dates.
1177
1178 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
1179
1180 * devices.in: Throughout use slashes instead of backslashes in the
1181 native path of devices not backed by native NT devices.
1182 * devices.cc: Regenerate.
1183 * globals.cc (ro_u_pmem): Use correct case.
1184 (ro_u_globalroot): New R/O unicode string.
1185 * path.cc (path_conv::check): Fix incorrect handling of /proc/sys
1186 block devices if they are just visited due to a component check.
1187 (symlink_info::posixify): Fix typo in comment.
1188 (cygwin_conv_path): Use ro_u_globalroot instead of string constant.
1189 (fast_cwd_version): New shared variable to store FAST_CWD version
1190 used on the system.
1191 (find_fast_cwd_pointer): Rename from find_fast_cwd_pointers. Don't
1192 set global fast_cwd_ptr pointer here. Return pointer value instead.
1193 (find_fast_cwd): New function to set fast_cwd_ptr and fast_cwd_version.
1194 (cwdstuff::override_win32_cwd): Call find_fast_cwd from here.
1195 Check for fast_cwd_version to differ between old and new FAST_CWD
1196 structure. Check old_cwd for NULL to avoid SEGV. Don't set CWD if
1197 we have neitehr a valid fast_cwd_ptr, nor a valid CWD handle in the
1198 process parameter block.
1199 (cwdstuff::set): Create Win32 path taking /proc/sys paths into account.
1200 * spawn.cc (spawn_guts): Recode creating runpath. Also take /proc/sys
1201 paths into account. Drop special CWD handling when starting non-Cygwin
1202 processes.
1203
1204 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
1205
1206 * fhandler_procsys.cc (fhandler_procsys::opendir): Avoid SEGV if
1207 opening object directory fails.
1208 * fhandler_virtual.cc (fhandler_virtual::opendir): Don't leak memory.
1209
1210 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
1211
1212 * fhandler_disk_file.cc (fhandler_disk_file::readdir_helper): Don't
1213 append slash if there is one already.
1214
1215 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
1216
1217 Revert change from 2010-08-31:
1218 * path.cc (normalize_posix_path): Drop support for //./ and //?/
1219 prefixes.
1220 (path_conv::check): Ditto.
1221
1222 2011-02-15 Corinna Vinschen <corinna@vinschen.de>
1223
1224 * fhandler_disk_file.cc (fhandler_disk_file::readdir_helper): Use POSIX
1225 path to check for symlink.
1226
1227 2011-02-14 Corinna Vinschen <corinna@vinschen.de>
1228
1229 * config/i386/profile.h: Sync with Mingw.
1230
1231 2011-02-13 Corinna Vinschen <corinna@vinschen.de>
1232
1233 * path.cc (struct _FAST_CWD): Redefine to new layout used since patch
1234 for KB 2393802. Adjust comments throughout.
1235 (struct _FAST_CWD_OLD): Rename former definition.
1236 (cwdstuff::override_win32_cwd): Check if the OS is using the old or the
1237 new FAST_CWD structure layout and handle accordingly.
1238
1239 2011-02-11 Christopher Faylor <me+cygwin@cgf.cx>
1240
1241 * mkstatic: Make sure that we are not cd'ed to temporary directory on
1242 exit to avoid bogus warnings on directory cleanup.
1243 * speclib: Ditto.
1244 * mkimport: Ditto.
1245
1246 2011-02-11 Christopher Faylor <me+cygwin@cgf.cx>
1247
1248 * cygwin.sc: Eliminate __cygheap_mid.
1249 * cygheap.cc: Ditto.
1250
1251 2011-02-11 Christopher Faylor <me+cygwin@cgf.cx>
1252
1253 * cygheap.cc (_cygheap_mid): Drop unneeded section attribute.
1254 (cygheap_init): Just zero cygheap structure.
1255 * cygwin.sc: Keep 16 byte alignment but drop all other alignments
1256 related to cygheap. Eliminate unused __cygheap_end1.
1257
1258 2011-02-11 Corinna Vinschen <corinna@vinschen.de>
1259
1260 * cygwin.sc: Raise default cygheap size to 1 Meg. Set alignment to
1261 standard 64K.
1262
1263 2011-02-11 Corinna Vinschen <corinna@vinschen.de>
1264
1265 * include/endian.h: Move definitions of __BIG_ENDIAN, __LITTLE_ENDIAN,
1266 and __BYTE_ORDER into ...
1267 * include/bits/endian.h: New file.
1268 * include/arpa/nameser_compat.h: Include endian.h rather than defining
1269 BYTE_ORDER here.
1270 * include/asm/byteorder.h: Include bits/endian.h. Drop definition of
1271 __LITTLE_ENDIAN.
1272 * include/netinet/ip.h: Include bits/endian.h. Drop definitions of
1273 BIG_ENDIAN, LITTLE_ENDIAN, and BYTE_ORDER. Use underscored variants
1274 of aforementioned constants.
1275 * include/netinet/tcp.h: Ditto.
1276 * include/sys/param.h: Drop disabled definitions of BIG_ENDIAN,
1277 LITTLE_ENDIAN, and BYTE_ORDER.
1278
1279 * include/netinet/ip.h: Reformat. Define setsockopt IP_TOS options
1280 matching recent RFCs. Tweak comments.
1281
1282 2011-02-10 Eric Blake <eblake@redhat.com>
1283
1284 * errno.cc (includes): Avoid compilation failure if <string.h>
1285 settles on wrong strerror_r signature.
1286
1287 * errno.cc (__xpg_strerror_r): New function.
1288 (strerror_r): Update to copy newlib's fixes.
1289 (strerror): Set errno on failure.
1290 (_sys_errlist): Cause EINVAL failure for reserved values.
1291 * cygwin.din: Export new function.
1292 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Combine
1293 this into minor 236.
1294
1295 2011-02-09 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
1296
1297 * cygwin.din (pthread_yield): Export as alias to sched_yield.
1298 * include/pthread.h (pthread_yield): Declare.
1299 * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
1300 * posix.sgml (std-deprec): Add pthread_yield.
1301
1302 2011-02-09 Christopher Faylor <me+cygwin@cgf.cx>
1303
1304 * cygheap.cc: Add some __stdcall decoration where appropriate.
1305 * lib/cygwin_crt0.c: __attribute -> __attribute__.
1306
1307 2011-02-09 Christopher Faylor <me+cygwin@cgf.cx>
1308
1309 * hookapi.cc (hook_or_detect_cygwin): Prevent i from being considered
1310 uninitialized by gcc.
1311
1312 2011-02-09 Christopher Faylor <me+cygwin@cgf.cx>
1313
1314 * exception.h: Remove DEBUG_EXCEPTION left over debugging ifdef.
1315
1316 2011-02-08 Christopher Faylor <me+cygwin@cgf.cx>
1317
1318 * dll_init.cc: Fix typo in comment.
1319
1320 2011-02-07 Corinna Vinschen <corinna@vinschen.de>
1321
1322 * configure.in: Remove AC_ALLOCA test and test for __builtin_memset.
1323 * configure: Regenerate.
1324
1325 2011-02-07 Corinna Vinschen <corinna@vinschen.de>
1326
1327 * fhandler_console.cc (fhandler_console::write_normal): Remove
1328 erroneous premature return after collecting truncated multibyte
1329 sequence in trunc_buf. Rather fall through to printing routine.
1330 Fix return value to take trunc_buf content into account. Improve
1331 comments.
1332
1333 2011-02-05 Christopher Faylor <me+cygwin@cgf.cx>
1334
1335 * autoload.cc (wsock_init): Properly define WSAStartup function pointer
1336 to avoid stack damage.
1337
1338 2011-02-02 Corinna Vinschen <corinna@vinschen.de>
1339
1340 * libc/bsdlib.cc: Include err.h.
1341
1342 2011-02-02 Eric Blake <eblake@redhat.com>
1343
1344 * include/err.h: Fix loss of semicolons in previous patch.
1345
1346 2011-02-02 Corinna Vinschen <corinna@vinschen.de>
1347
1348 * include/err.h (err): Add noreturn attribute.
1349 (errx): Ditto.
1350 (verr): Ditto.
1351 (verrx): Ditto.
1352
1353 2011-02-02 Corinna Vinschen <corinna@vinschen.de>
1354
1355 * path.cc (conv_path_list): Remove enclosing quotes and trailing
1356 backslashes from Win32 environment path lists.
1357
1358 2011-02-01 Christian Franke <franke@computer.org>
1359
1360 * fhandler.cc (fhandler_base::fsync): Ignore ERROR_INVALID_FUNCTION
1361 error from FlushFileBuffers().
1362
1363 2011-01-31 Corinna Vinschen <corinna@vinschen.de>
1364
1365 * syscalls.cc (utmp_data): Fix potential buffer overflow.
1366
1367 2011-01-31 Corinna Vinschen <corinna@vinschen.de>
1368
1369 * fhandler_socket.cc (address_in_use): Improve comment readability.
1370
1371 2011-01-30 Corinna Vinschen <corinna@vinschen.de>
1372
1373 * fhandler_socket.cc (address_in_use): Disable. Add comment.
1374 (fhandler_socket::bind): Change comment to explain setting the
1375 SO_EXCLUSIVEADDRUSE socket option. Remove code which checks for
1376 address in use.
1377 * net.cc (cygwin_setsockopt): Never set SO_REUSEADDR option. Improve
1378 comment to compensate for the deleted comment in fhandler_socket::bind.
1379 * wincap.cc: Throughout, drop has_enhanced_socket_security from wincaps.
1380 * wincap.h (struct wincaps): Drop has_enhanced_socket_security flags
1381 and method.
1382
1383 2011-01-28 Peter Foley <jpfoley2@verizon.net>
1384
1385 * configure.in: Define LIBSERVER regardless of cross_host.
1386 * configure: Regenerate.
1387
1388 2011-01-28 Corinna Vinschen <corinna@vinschen.de>
1389
1390 * fhandler_socket.cc (fhandler_socket::wait_for_events): Call
1391 pthread_testcancel in case of timeout to enable pthread_cancel
1392 on waiting thread.
1393
1394 2011-01-27 Corinna Vinschen <corinna@vinschen.de>
1395
1396 * include/features.h (__STDC_ISO_10646__): Move to newlib's
1397 sys/features.h.
1398
1399 2011-01-26 Corinna Vinschen <corinna@vinschen.de>
1400
1401 * fhandler_disk_file.cc (fhandler_base::fstat_by_nfs_ea): Fix
1402 computation of st_blocks.
1403 (fhandler_base::fstat_helper): Fix formatting.
1404
1405 2011-01-24 Corinna Vinschen <corinna@vinschen.de>
1406
1407 * include/features.h (__STDC_ISO_10646__): Define. Add comment.
1408
1409 2011-01-21 Corinna Vinschen <corinna@vinschen.de>
1410
1411 * syscalls.cc (rename): Fix permission problem with symlinks on NFS.
1412 Rework how NtOpenFile gets called to make it more readable. Change
1413 comment.
1414
1415 2011-01-20 Corinna Vinschen <corinna@vinschen.de>
1416
1417 * exec.cc: Include pinfo.h.
1418 * winf.h: Move definitions of _P_PATH_TYPE_EXEC and _P_MODE from here...
1419 * pinfo.h: ...to here.
1420 (_P_PATH_TYPE_EXEC): Redefine to be bigger than _P_SYSTEM.
1421 (_P_MODE): Redefine so as not to mask out _P_SYSTEM.
1422 * spawn.cc (spawnlp): Add _P_PATH_TYPE_EXEC flag in call to spawnve.
1423 (spawnlpe): Ditto.
1424 (spawnvp): Ditto.
1425
1426 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
1427
1428 * spawn.cc (av::fixup): Reenable #! handling for all exec functions.
1429 Return ENOEXEC in !p_type_exec case only for unrecognized files.
1430 Fix comment formatting.
1431
1432 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
1433
1434 * exec.cc (execlp): Add missing _P_PATH_TYPE_EXEC flag in call to
1435 spawnve.
1436
1437 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
1438
1439 * exec.cc: Rearrange functions in alphabetical order.
1440 (_execve): Drop temporary define and drop export alias.
1441 (execl): Call spawnve.
1442 (execle): New function.
1443 (execlp): New function.
1444 (execv): Call spawnve.
1445 (execve): Drop converting NULL envp to emtpy envp.
1446 (execvp): Call spawnve.
1447 (execvpe): Drop converting NULL envp to emtpy envp. Call spawnve.
1448 (fexecve): Call spawnve.
1449 * spawn.cc (spawnve): Convert NULL envp to emtpy envp. Remove outdated
1450 comment.
1451 (spawnlp): Call spawnve.
1452 (spawnlpe): Ditto.
1453 (spawnvp): Ditto.
1454 (spawnvpe): Fix formatting.
1455
1456 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
1457
1458 * exec.cc (strccpy): Move function from here...
1459 * strfuncs.cc (strccpy): ...to here.
1460 * string.h (strccpy): Declare.
1461 * winsup.h (strccpy): Drop declaration.
1462
1463 2011-01-19 Corinna Vinschen <corinna@vinschen.de>
1464
1465 * errno.cc (errmap): Add error codes for invalid binaries.
1466 * exec.cc (execvp): Call spawnve with _P_PATH_TYPE_EXEC flag
1467 from here.
1468 (execvpe): Ditto.
1469 * spawn.cc (spawn_guts): Filter _P_PATH_TYPE_EXEC from mode and
1470 store in p_type_exec. Call av::fixup with addtional p_type_exec
1471 argument.
1472 (spawnve): Check for filtered mode.
1473 (spawnvpe): Add _P_PATH_TYPE_EXEC flag when calling spawnve.
1474 (av::fixup): Accept additional bool parameter p_type_exec. Only check
1475 for script if p_type_exec is true.
1476 * winf.h (_P_PATH_TYPE_EXEC): Define.
1477 (_P_MODE): Define.
1478 (av::fixup): Declare with additional bool parameter.
1479
1480 2011-01-17 Corinna Vinschen <corinna@vinschen.de>
1481
1482 * fhandler_proc.cc (format_proc_partitions): Fix compiler warning.
1483
1484 2011-01-17 Corinna Vinschen <corinna@vinschen.de>
1485
1486 * path.cc (path_conv::check): Don't follow reparse point symlinks if
1487 PC_SYM_NOFOLLOW_REP flag is set.
1488 (cygwin_conv_path): Set PC_SYM_NOFOLLOW_REP flag when converting from
1489 POSIX to Win32.
1490 * path.h (enum pathconv_arg): Define PC_SYM_NOFOLLOW_REP flag.
1491
1492 2011-01-17 Corinna Vinschen <corinna@vinschen.de>
1493
1494 * fhandler_proc.cc (proc_tab_cmp): Fix typo in comment.
1495 (fhandler_proc::fill_filebuf): Handle return value of 0 from format
1496 function as error.
1497 (format_proc_stat): Set errno when returning 0 size.
1498 (format_proc_partitions): Rewrite method to fetch partition info.
1499
1500 2011-01-13 Corinna Vinschen <corinna@vinschen.de>
1501
1502 * fhandler_disk_file.cc (fhandler_base::fstat_helper): Always set
1503 st_size of directories to 0. Explain why.
1504
1505 2011-01-12 Corinna Vinschen <corinna@vinschen.de>
1506
1507 * posix.sgml: Add madvise to BSD list.
1508
1509 2011-01-12 Corinna Vinschen <corinna@vinschen.de>
1510
1511 * cygwin.din (madvise): Export posix_madvise as madvise.
1512 * include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR.
1513 * include/sys/mman.h: Define madvise constants, keep Linux-specific
1514 constants undefined.
1515 (madvise): Declare.
1516
1517 2011-01-12 Corinna Vinschen <corinna@vinschen.de>
1518
1519 * fhandler.h (struct part_t): New type.
1520 (class fhandler_dev_floppy): Convert partitions to part_t pointer.
1521 Add lock_partition method.
1522 * fhandler_floppy.cc (fhandler_dev_floppy::lock_partition): New method
1523 to implement ondemand partition locking.
1524 (fhandler_dev_floppy::write_file): Call lock_partition from here if
1525 writing failed due to a potential write restriction on a disk
1526 partition.
1527 (fhandler_dev_floppy::open): Don't lock partitions here.
1528 (fhandler_dev_floppy::close): Keep track of partition handle reference
1529 count. Close handles and remove partitions pointer ony if count is 0.
1530 (fhandler_dev_floppy::dup): Just copy partitions pointer and increment
1531 reference count.
1532
1533 2011-01-11 Corinna Vinschen <corinna@vinschen.de>
1534
1535 * fhandler.h (MAX_PARTITIONS): New definition.
1536 (class fhandler_dev_floppy): Add partitions array member. Add close
1537 method.
1538 * fhandler_floppy.cc (fhandler_dev_floppy::fhandler_dev_floppy): Zero
1539 out partitions array.
1540 (fhandler_dev_floppy::open): Fix "entire disk" condition for call to
1541 DeviceIoControl (FSCTL_ALLOW_EXTENDED_DASD_IO).
1542 When opening disks for writing, call DeviceIoControl (FSCTL_LOCK_VOLUME)
1543 on all affected disk partitions starting with Vista.
1544 (fhandler_dev_floppy::close): New method.
1545 (fhandler_dev_floppy::dup): Duplicate handles in partitions, if any.
1546 * wincap.h (wincaps::has_restricted_raw_disk_access): New element.
1547 * wincap.cc: Implement above element throughout.
1548
1549 2011-01-11 Yaakov Selkowitz <yselkowitz@users.sourceforge.net>
1550
1551 * termios.cc (cfgetospeed, cfgetispeed): Constify argument per POSIX.
1552 * include/sys/termios.h (cfgetospeed, cfgetispeed): Declare functions.
1553 Move macros after declarations and make conditional on !__cplusplus.
1554
1555 2011-01-11 Corinna Vinschen <corinna@vinschen.de>
1556
1557 * cygtls.cc (_cygtls::init_thread): Call _REENT_INIT_PTR. Drop setting
1558 current locale and calling srand48.
1559
1560 2011-01-02 Christopher Faylor <me+cygwin@cgf.cx>
1561
1562 * ChangeLog-2010: Create from ChangeLog.
1563 * ChangeLog: Start fresh.
This page took 0.098546 seconds and 6 git commands to generate.