]> sourceware.org Git - newlib-cygwin.git/blame - winsup/cygwin/ChangeLog
* path.cc (special_name): Accommodate all special names with extensions.
[newlib-cygwin.git] / winsup / cygwin / ChangeLog
CommitLineData
293ce810
CF
12003-08-17 Christopher Faylor <cgf@redhat.com>
2
3 * path.cc (special_name): Accommodate all special names with
4 extensions.
5
92d897cd
CV
62003-08-15 Corinna Vinschen <corinna@vinschen.de>
7
8 * mmap.cc (mmap64): Avoid crash if file size is less than requested
9 map length.
10
6763d47b
CV
112003-08-13 Igor Pechtchanski <pechtcha@cs.nyu.edu>
12
13 * path.cc (special_name): Add checks for some specials followed by
14 a "." and a FIXME comment.
15
ae89a496
CV
162003-08-13 Corinna Vinschen <corinna@vinschen.de>
17
293ce810 18 * cygwin.din: Accommodate change from cygwin_lstat to lstat.
ae89a496
CV
19 * syscalls.cc: Add defines to avoid declaration issues when
20 renaming cygwin_lstat back to lstat.
21 (lstat): Reverted name change from cygwin_lstat.
22
c86c10b8
CV
232003-08-12 Corinna Vinschen <corinna@vinschen.de>
24
25 * include/sys/param.h (NBBY): Define if not defined.
26
272003-08-12 Nicholas Wourms <nwourms@netscape.net>
28
29 * include/sys/param.h (setbit): Add new bitmap related macro.
30 (clrbit): Likewise.
31 (isset): Likewise.
32 (isclr): Likewise.
33 (howmany): Add new counting/rounding macro.
34 (rounddown): Likewise.
35 (roundup): Likewise.
36 (roundup2): Likewise.
37 (powerof2): Likewise
38 (MIN): Add macro for calculating min.
39 (MAX): Add macro for calculating max.
40
9d77d536
CF
412003-08-09 Christopher Faylor <cgf@redhat.com>
42
43 * include/cygwin/version.h: Bump DLL minor number to 3.
44
5c65fa02
CF
452003-08-08 Gerrit P. Haase <gp@familiehaase.de>
46
47 * include/stdint.h: Correctly define INT32_MIN.
48
b344f187
CF
492003-08-08 David Rothenberger <daveroth@acm.org>
50
51 * grp.cc (read_group): Set __group32.gr_mem pointer back to &null_ptr
52 after free() is called.
53
4b154cc1
CF
542003-08-05 Christopher Faylor <cgf@redhat.com>
55
56 * Makefile.in: Rework to accommodate new speclib arguments.
57 * speclib: Rework to extract everything from libcygwin.a rather than
58 building things from existing object files.
59
4423d924
CF
602003-08-05 Pavel Tsekov <ptsekov@gmx.net>
61
62 * path.cc (cygdrive_getmntent): Do not skip over drives of type
63 DRIVE_REMOVABLE.
64
652003-08-05 Christopher Faylor <cgf@redhat.com>
66
67 * fhandler.cc (fhandler_base::lseek): Be more paranoid when
68 constructing offsets from 64 bit value.
69 * syscalls.cc (logout): Avoid temp buffer memcpy since new scheme does
70 not require it.
71 (utmp_data): Rework as a macro which returns a pointer into a buffer.
72 (getutent): Use new buffer allocation mechanism to grab a utmp buffer.
73 (getutid): Ditto.
74 (pututline): Ditto.
75
3fea2e40
CF
762003-08-05 Pavel Tsekov <ptsekov@gmx.net>
77
78 * fhandler_disk_file.cc (fhandler_cygdrive::readdir): Do not change
79 'errno' if end of directory condition is encountered as per SUSv2.
80 * fhandler_proc.cc (fhandler_proc::readdir): Ditto.
81 * fhandler_process (fhandler_process::readdir): Ditto.
82 * fhandler_registry (fhandler_registry::readdir): Ditto.
83
b9621e8d
CF
842003-07-30 Christopher Faylor <cgf@redhat.com>
85
86 * dcrt0.cc (_dll_crt0): Move strace.microseconds initialization to
87 after pthread initialization.
88 (dll_crt0_1): i.e., here.
89
d2466c7a
CF
902003-07-28 Christopher Faylor <cgf@redhat.com>
91
92 * fhandler_base.cc (fhandler_base::readv): Rework to properly return
93 number of bytes from read.
94
8e2315f0
CF
952003-07-28 Christopher Faylor <cgf@redhat.com>
96
97 * include/cygwin/version.h: Bump DLL minor number to 2.
98
df04ae29
CF
992003-07-26 Christopher Faylor <cgf@redhat.com>
100
101 * exceptions.cc (ctrl_c_handler): Send SIGHUP when events occur only if
102 there is a tty associated with the process. Send SIGHUP on
103 CTRL_LOGOFF_EVENT.
104
105 * fhandler_tty.cc (fhandler_tty_slave::open): Adjust console open
106 handle counter regardless of whether this is a pty or tty.
107 (fhandler_tty_slave::open): Ditto.
108 (fhandler_tty_slave::dup): Ditto.
109 (fhandler_tty_common::set_close_on_exec): Ditto.
110 (fhandler_tty_master::init_console): Decrement console open handle
111 counter after init since it will now be handled by all tty open.
112 * syscalls.cc (setsid): Rework debugging output slightly.
113
ddb67621
CF
1142003-07-25 Christopher Faylor <cgf@redhat.com>
115
116 * configure.in: Use 'install-sh -c'.
117 * configure: Regenerate.
118
7f4773b3
CF
1192003-07-25 Christopher Faylor <cgf@redhat.com>
120
121 * configure.in: Always use install-sh.
122 * configure: Regenerate.
123
5d66faab
CF
1242003-07-25 Christopher Faylor <cgf@redhat.com>
125
126 * include/cygwin/socket.h: Conditionalize [AP]F_INET6 define.
127
6f8c86ae
CF
1282003-07-25 Christopher Faylor <cgf@redhat.com>
129
130 * Makefile.in (OBSOLETE_FUNCTION): Add fdopen.
131
86ed5c88
CF
1322003-07-25 Christopher Faylor <cgf@redhat.com>
133
134 * cygwin.din: Export _fdopen64
135 * Makefile.in (NEW_FUNCTIONS): Add _fdopen64 -> fdopen translation.
136 * include/cygwin/version.h: Bump api minor number.
137
138 * ntdll.h: Remove (now) duplicate FILE_SYNCHRONOUS_IO_NONALERT
139 definition.
140
1fbeb827
CF
1412003-07-24 Christopher Faylor <cgf@redhat.com>
142
143 * environ.cc (check_case_init): Use strncasematch.
144
145 * cygwin.din: Export __mempcpy.
146 * cygwin/version.h: Bump api minor number.
147
d432ac75
CV
1482003-07-21 Pavel Tsekov <ptsekov@gmx.net>
149
150 * mmap.cc: Use proper format specifiers for _off64_t and size_t in
151 format strings passed to syscall_printf () and debug_printf ()
152 throughout.
153
b4ece40c
PH
1542003-07-18 Pierre Humblet <pierre.humblet@ieee.org>
155
156 * security.cc (verify_token): Fix white space and style.
157 Use type bool instead of BOOL and char. Use alloca
df04ae29 158 instead of malloc and free for my_grps.
b4ece40c 159
fc2843ca
CV
1602003-07-17 Corinna Vinschen <corinna@vinschen.de>
161
162 * sysconf.cc (sysconf): Fix OPEN_MAX patch. Return page size on
163 _SC_PAGESIZE again.
164
ea3ba114
CV
1652003-07-14 Corinna Vinschen <corinna@vinschen.de>
166
167 * cygheap.h (class cygheap_user): Use INVALID_HANDLE_VALUE as invalid
168 value for tokens.
169 * syscalls.cc (seteuid32): Ditto. Set new_token to process token if
170 process token is suitable.
171 * uinfo.cc (uinfo_init): Initialize tokens in cygheap user info
172 to INVALID_HANDLE_VALUE.
173
1742003-07-14 Pierre Humblet <pierre.humblet@ieee.org>
175
176 * cygheap.h (enum impersonation): Delete.
177 (cygheap_user::impersonation_state): Delete.
178 (cygheap_user::current_token): New.
179 (cygheap_user::issetuid): Modify to use current_token.
180 (cygheap_user::token): Ditto.
181 (cygheap_user::deimpersonate): Ditto.
182 (cygheap_user::reimpersonate): Ditto.
183 (cygheap_user::has_impersonation_tokens): Ditto.
184 (cygheap_user::close_impersonation_tokens): Ditto.
185 * security.cc (cygwin_set_impersonation_token): Always set the token.
186 (verify_token): Change type of gsid to cygpsid.
187 (get_file_attribute): Use the effective ids.
188 * syscalls.cc (seteuid32): Modify to use cygheap_user::current_token.
189 * uinfo.cc (uinfo_init) Do not set cygheap->user.impersonation_state.
190
9e8ac0ae
CF
1912003-07-12 Christopher Faylor <cgf@redhat.com>
192
193 * pinfo.cc (_pinfo::commune_send): Fix bounds test so that poll of
194 communicating pid actually stops eventually.
195
e47d5648
CF
1962003-07-10 Christopher Faylor <cgf@redhat.com>
197
198 * path.cc (get_device_number): Remove special com? consideration.
199 (special_chars): Make static.
200 (special_introducers): New.
201 (special_char): Allow specified valid_chars args.
202 (fnunmunge): Handle aux-like filenames correctly.
203 (special_name): Add con, conin$, conout$.
204 (mount_item::fnmunge): Use __small_sprintf return value to calculate
205 increments.
206
30811232
CF
2072003-07-09 Christopher Faylor <cgf@redhat.com>
208
209 * include/cygwin/version.h: Bump DLL minor number to 1.
210
f1a4b6b5
CF
2112003-07-09 Christopher Faylor <cgf@redhat.com>
212
2f5cab7b
CF
213 * fhandler_proc.cc (format_proc_stat): Use correctly sized constants
214 for filling in zeros on 98.
f1a4b6b5 215
cf38615c
CF
2162003-07-09 Christopher Faylor <cgf@redhat.com>
217
218 * fhandler_proc.cc (fhandler_proc::fill_filebuf): Allocate more space
219 for stat buffer.
220 (format_proc_stat): Reorganize to accumulate and report on all cpus.
221
ab3dc80d
CF
2222003-07-09 Christopher Faylor <cgf@redhat.com>
223
224 * sysconf.cc (sysconf): Return processors online rather than bitmask
225 for _SC_NPROCESSORS_ONLN.
226
4d782b42
CF
2272003-07-08 Christopher Faylor <cgf@redhat.com>
228
229 * cygheap.cc (creturn): Set appropriate errno when out of memory.
230 (ccalloc): Only issue system_printf when debugging.
231 * dtable.cc (dtable::extend): Only allocate 100 * the incremental growth
232 size max. Set errno appropriately.
233 (dtable::build_fhandler): Check for error from set_name.
234 * fhandler.cc (fhandler_base::set_name): Set errno and return error on OOM.
235 * fhandler.h (fhandler_base::set_name): Change to bool.
236 * fhandler_process.cc (format_process_stat): Fix formatting.
237 * resource.cc (getrlimit): Return greater of OPEN_MAX or fd table size.
238 * sysconf.cc (sysconf): Ditto.
239
a711a5af
CF
2402003-07-07 Christopher Faylor <cgf@redhat.com>
241
242 * rmsym: Don't use ranlib.
243
c0a6fcd7
CF
2442003-07-07 Christopher Faylor <cgf@redhat.com>
245
246 * newsym: Reenable removal of tmp directory. Just use ar to generate
247 archive index.
a711a5af 248 * Makefile.in: Don't send ranlib to newsym or rmsym.
c0a6fcd7 249
0e5db0bf
CF
2502003-07-07 Christopher Faylor <cgf@redhat.com>
251
252 * newsym: Create objects that are closer to those created by dlltool so
253 as not to confuse --export-all-symbols.
254 * rmsym: Be a little more accepting of object filenames now that
255 dlltool can create different format files.
256
c522b907
CF
2572003-07-06 Christopher Faylor <cgf@redhat.com>
258
259 * newsym: Oops. Revert below change.
260
88a62816
CF
2612003-07-06 Christopher Faylor <cgf@redhat.com>
262
263 * newsym: Use correct prefix for generating imports.
264 * pinfo.cc (_pinfo::commune_send): Don't wait forever for a response
265 from another process.
266
b6717153
CF
2672003-07-06 Christopher Faylor <cgf@redhat.com>
268
269 * syscalls.cc (gethostid): Set thread affinity so that results are
270 predictable.
271
f2d3c47b
CV
2722003-07-05 Corinna Vinschen <corinna@vinschen.de>
273
274 * mmap.cc (list::match): Add parameters to return valid address and
275 length back to munmap(). Evaluate intersection between given
276 area and mapped area and return it, if any.
277 (mmap64): On regular files, don't allow mappings beginning beyond
278 EOF. Return with errno set to ENXIO instead.
279 (munmap): Rewrite SUSv3 conformant. Check if given memory area is
280 valid. Unmap all maps inside given memory area. Don't return error
281 if no mapping has been unmapped.
282
2832003-07-05 N Stephens <nigel@mips.com>
4b2cbaee
CV
284
285 * fhandler.h (fhandler_socket::get_connect_state): New method to
286 return socket connection state.
287 * fhandler_socket.cc (dup): Copy socket connect state to new file
288 handle.
289 * net.cc (cygwin_rcmd): Mark file handles of sockets returned by
290 rcmd() as CONNECTED state.
291 (cygwin_rexec): Similarly for rexec().
292 (socketpair): Mark both ends of a new socket pair as CONNECTED.
293
6694f305
CV
2942003-07-04 Corinna Vinschen <corinna@vinschen.de>
295
296 * mmap.cc (fhandler_disk_file::mmap): Fix address test.
297
d108f312
CF
2982003-07-03 Christopher Faylor <cgf@redhat.com>
299
300 * path.cc (fillout_mntent): Change "posix" to "managed".
301
3f214783
CF
3022003-07-02 Christopher Faylor <cgf@redhat.com>
303
304 * fhandler.h (FH_ENC): New enum.
305 (fhandler_base::get_encoded): New function.
306 (fhandler_base::set_encoded): Ditto.
307 * fhandler_disk_file.cc (fhandler_disk_file::opendir): Set encoded flag
308 in fhandler, as appropriate.
309 (fhandler_disk_file::readdir): Unmunge filename as appropriate based on
310 new encoding flag.
311 * path.cc (normalize_posix_path): Don't punt on files with colons.
312 (special_char): New function.
313 (mount_item::fnmunge): Ditto.
314 (fnunmunge): Ditto.
315 (special_name): Ditto.
316 (mount_item::build_win32): Avoid drive considerations when file is
317 encoded.
318 (mount_info::conv_to_win32_path): Handle encoded filenames.
319 (mount_info::conv_to_posix_path): Ditto.
320 (fillout_mntent): Add posix string when directory is encoded.
321 * path.h (fnunmunge): Declare.
322 (path_conv::is_encoded): Declare.
323
3d8a75bd
CF
3242003-07-03 Christopher Faylor <cgf@redhat.com>
325
326 * fhandler_tty.cc (fhandler_tty_slave::open): Conditionalize a little
327 more of the cygserver stuff so that ttys actually work.
328
65561780
CV
3292003-07-03 Corinna Vinschen <corinna@vinschen.de>
330
331 * mmap.cc (mmap64): Allow MAP_FIXED with pagesize granularity (4K).
332 If a non-zero addr is given, align it to the next lower 64K boundary.
333 (fhandler_disk_file::mmap): If a non-zero address is given, try
334 mapping using the given address first. If it fails and flags is not
335 MAP_FIXED, try again with NULL address.
336
3372003-07-01 Christopher Faylor <cgf@redhat.com>
338
339 * thread.cc: Remove _MT_SAFE conditional.
340
3412003-07-01 Christopher Faylor <cgf@redhat.com>
342
343 * configure.in: Fix --enable-server option.
344 * configure: Regenerate.
345
3462003-07-01 Christopher Faylor <cgf@redhat.com>
347
348 * Makefile.in: Remove cygserver stuff.
349 * acconfig.h: Add USE_CYGSERVER define.
350 * config.h.in: Regenerate.
351 * configure.in: Add --enable-server setting.
352 * configure: Regenerate.
353 * fhandler_tty.cc (fhandler_tty_slave::open): Conditionalize
354 compilation of cygserver stuff.
355 * fork.cc (fork_child): Ditto.
356 * shm.cc: Ditto.
357 * tty.cc (tty::common_init): Ditto.
358
359 * dcrt0.cc: Use bool rather than BOOL for CYGWIN environment variable
360 definitions.
361 * environ.cc: Ditto.
362 * ntea.cc: Ditto.
363 * security.cc: Ditto.
364 * security.h: Ditto.
365 * syscalls.cc (check_posix_perm): Remove externs that were already
366 declared in a header.
367 * winsup.h: Ditto. Declare _MT_SAFE here. Delete it someday since
368 cygwin should always be _MT_SAFE.
369
f3ff0ca9
CF
3702003-07-01 Christopher Faylor <cgf@redhat.com>
371
372 * thread.cc: Remove _MT_SAFE conditional.
373
8fb2df19
CF
3742003-07-01 Christopher Faylor <cgf@redhat.com>
375
376 * configure.in: Fix --enable-server option.
377 * configure: Regenerate.
378
3872e9a4
CF
3792003-07-01 Christopher Faylor <cgf@redhat.com>
380
381 * Makefile.in: Remove cygserver stuff.
382 * acconfig.h: Add USE_CYGSERVER define.
383 * config.h.in: Regenerate.
384 * configure.in: Add --enable-server setting.
385 * configure: Regenerate.
386 * fhandler_tty.cc (fhandler_tty_slave::open): Conditionalize
387 compilation of cygserver stuff.
388 * fork.cc (fork_child): Ditto.
389 * shm.cc: Ditto.
390 * tty.cc (tty::common_init): Ditto.
391
392 * dcrt0.cc: Use bool rather than BOOL for CYGWIN environment variable
393 definitions.
394 * environ.cc: Ditto.
395 * ntea.cc: Ditto.
396 * security.cc: Ditto.
397 * security.h: Ditto.
398 * syscalls.cc (check_posix_perm): Remove externs that were already
399 declared in a header.
400 * winsup.h: Ditto. Declare _MT_SAFE here. Delete it someday since
401 cygwin should always be _MT_SAFE.
402
70249d56
CV
4032003-06-30 Pierre Humblet <pierre.humblet@ieee.org>
404
405 * cygheap.h (enum impersonation): New enum.
406 (cygheap_user::token): Delete.
407 (cygheap_user::impersonated): Delete.
408 (cygheap_user::external_token): New member.
409 (cygheap_user::internal_token): New member.
410 (cygheap_user::impersonation_state): New member.
411 (cygheap_user::issetuid): Modify.
b6717153 412 (cygheap_user::token): New method.
70249d56
CV
413 (cygheap_user::deimpersonate): New method.
414 (cygheap_user::reimpersonate): New method.
415 (cygheap_user::has_impersonation_tokens): New method.
416 (cygheap_user::close_impersonation_tokens): New method.
417 * dtable.cc (dtable::vfork_child_dup): Use new cygheap_user methods.
418 * fhandler_socket.cc (fhandler_socket::dup): Ditto.
419 * fork.cc (fork_child): Ditto.
420 (fork_parent): Ditto.
421 * grp.cc (internal_getgroups): Ditto.
422 * security.cc (verify_token): Ditto.
423 (check_file_access): Ditto.
424 (cygwin_set_impersonation_token): Detect conflicts. Set
425 user.external_token.
426 * spawn.cc (spawn_guts): Use new cygheap_user methods.
427 * syscalls.cc (seteuid32): Rearrange to use the two tokens
428 in cygheap_user.
429 (setegid32): Use new cygheap_user methods.
430 * uinfo.cc: (internal_getlogin): Ditto.
431
b06d4a08
CF
4322003-06-25 Doru Carastan <doru.carastan@mvista.com>
433
434 * Makefile.in: Use INSTALL_PROGRAM to install the cygwin DLL.
435
e1e196a2
TP
4362003-06-24 Thomas Pfaff <tpfaff@gmx.net>
437
438 * thread.cc (MTinterface::fixup_after_fork): Fix thread list after
439 fork.
440 (pthread::threads): Instantiate.
441 (pthread::pthread): Initialize running and suspendend.
442 Initialize next with NULL.
443 Add thread to thread list if it is not the null_pthread.
444 (pthread::~pthread): Remove thread from thread list if it is
445 not the null_pthread.
446 (pthread::postcreate): Set running flag.
447 (pthread::exit): Reset running flag.
448 (pthread::cancel): Try to cancel thread only if still running.
449 (pthread::_fixup_after_fork): Implement.
450 (pthread::detach): Check if thread is still running before detach.
451 * thread.h (pthread::running): New member.
452 (pthread::next): Ditto.
453 (pthread::fixup_after_fork): New static method.
454 (pthread::threads): New static method.
455 (pthread::_fixup_after_fork): New method.
456
6c6f7094
CF
4572003-06-20 Christopher Faylor <cgf@redhat.com>
458
459 * pinfo.cc (_pinfo::commune_send): Don't attempt to communicate with a
460 pure windows process.
461
c9a5cfa0
PH
4622003-06-18 Pierre Humblet <pierre.humblet@ieee.org>
463
b6717153
CF
464 * autoload.cc (GetNetworkParams): Add.
465 * net.cc (getdomainname): Call GetNetworkParams and read the
466 DhcpDomain registry value if warranted.
c9a5cfa0 467
0d58ef9d
CF
4682003-06-17 Christopher Faylor <cgf@redhat.com>
469
470 * path.cc (mount): Do more strict checking on posix path arguments.
471
c433f461
CF
4722003-06-15 Christopher Faylor <cgf@redhat.com>
473
474 Throughout, remove "include <errno.h>" from files which already include
475 cygerrno.h.
476
4772003-06-15 Thomas Pfaff <tpfaff@gmx.net>
478
479 * include/cygwin/config.h (__DYNAMIC_REENT__): Define.
480 * include/cygwin/version.h: Bump API minor version.
481 * cygwin.din: Export __getreent
482 * cygerrno.h: Include errno.h. Fix places where _impure_ptr is used
483 directly to store the errno value.
484 * debug.cc (__set_errno): Ditto.
485 * errno.cc: Remove _RRENT_ONLY define to get errno.cc compiled.
486 * signal.cc: Rename _reent_clib to _REENT throughout.
487 * thread.h (reent_clib): Remove prototype.
488 * thread.cc (reent_clib): Rename reent_clib to __getreent. Return
489 _impure_ptr until MTinterface is initialized.
490 (reent_winsup): Fix a possible SEGV when _r == NULL. Return NULL
491 instead.
492 * MTinterface::fixup_after_fork: Switch reent back to _impure_ptr to
493 keep signal handling running when fork is called from a thread other
494 than the mainthread.
495
1c80421c
TP
4962003-06-12 Thomas Pfaff <tpfaff@gmx.net>
497
498 * thread.cc (pthread_attr_init): Revert change from 2003-06-11
499 to return 0 if attribute is already initialized back to EBUSY.
500 (pthread_condattr_init): Ditto.
501 (pthread_rwlockattr_init): Ditto.
502 (pthread_mutexattr_init): Ditto.
503
5bdb56f0
CV
5042003-06-12 Corinna Vinschen <corinna@vinschen.de>
505
506 * exceptions.cc (ctrl_c_handler): Don't send a signal on
507 CTRL_SHUTDOWN_EVENT. Add a comment to rationalize the patch.
508
00e6660b
TP
5092003-06-11 Thomas Pfaff <tpfaff@gmx.net>
510
511 * thread.cc (pthread_attr_init): Return 0 if attribute is already
512 initialized.
513 Fix return code if out of memory.
514 (pthread_condattr_init): Ditto.
515 (pthread_rwlockattr_init): Ditto.
516 (pthread_mutexattr_init): Return 0 if attribute is already
517 initialized.
518
271c1935
CV
5192003-06-09 Pierre Humblet <pierre.humblet@ieee.org>
520
521 * spawn.cc (spawn_guts): Call CreateProcess while impersonated,
522 when the real {u,g}ids and the groups are original.
523 Move RevertToSelf and ImpersonateLoggedOnUser to the main line.
524 * uinfo.cc (uinfo_init): Reorganize. If CreateProcess was called
525 while impersonated, preserve the uids and gids and call
526 ImpersonateLoggedOnUser. Preserve the uids and gids on Win9X.
527
528 * exceptions.cc (error_start_init): Quote the pgm in the command.
529
42a737d0
CF
5302003-06-07 Christopher Faylor <cgf@redhat.com>
531
532 * poll.cc: Define FD_SETSIZE to ridiculously large number so that there
32173f7e 533 will be no artificially small limits.
42a737d0 534
9501a0a1
CF
5352003-06-07 Christopher Faylor <cgf@redhat.com>
536
537 * fhandler_tty.cc (fhandler_tty_slave::close): Free the console when
538 last tty closes.
539
f496071c
TP
5402003-06-07 Thomas Pfaff <tpfaff@gmx.net>
541
542 * fhandler_socket.cc (fhandler_socket::connect): Change error
543 handling for nonblocking connects to return EALREADY when
544 connect is called more than once for the same socket.
545
54152c7e
CV
5462003-06-06 Corinna Vinschen <corinna@vinschen.de>
547
548 * cygwin.din: Add vsyslog.
549 * fhandler.cc (fhandler_base::write): Only make file sparse if the
550 seeked area is >= 128K.
551 * syslog.cc (vsyslog): New function, overtaking functionality from
552 syslog.
553 (syslog): Just call vsyslog.
554 * include/cygwin/version.h: Bump API minor.
555 * include/sys/syslog.h: Add vsyslog declaration.
556
979233a5
CF
5572003-06-05 Christopher Faylor <cgf@redhat.com>
558
559 * cygthread.cc (cygthread::terminate_thread): Change system_printf to
560 debug_printf.
561
f51e42ac
CF
5622003-06-04 Christopher Faylor <cgf@redhat.com>
563
564 * shared.cc (shared_info::heap_chunk_size): Be really defensive about
565 making sure that heap_chunk is set.
566
7b17543f
CF
5672003-06-04 Christopher Faylor <cgf@redhat.com>
568
569 * path.cc (conv_path_list): Use correct value when calculating length
570 to avoid a potential SEGV.
571
9f033c22
PH
5722003-06-03 Pierre Humblet <pierre.humblet@ieee.org>
573
271c1935
CV
574 * fhandler_disk_file.cc (fhandler_disk_file::fstat): Mark the pc
575 as non-executable if the file cannot be opened for read. Retry query
576 open only if errno is EACCES. Never change the mode, even if it is 000
577 when query open() fails.
9f033c22 578
1e61337c
CF
5792003-06-03 Christopher Faylor <cgf@redhat.com>
580
581 * configure.in: Allow any i?86 variant.
582 * configure: Regenerate.
583
fb6b1418
CV
5842003-06-03 Corinna Vinschen <corinna@vinschen.de>
585 Thomas Pfaff <tpfaff@gmx.net>
586
587 * fhandler_socket.cc (connect_thread): Remove.
588 (accept_thread): Remove.
589 (fhandler_socket::connect): Remove all special blocking handling.
590 (fhandler_socket::accept): Ditto.
591 * net.cc (cygwin_connect): Make blocking sockets temporarily
592 non-blocking and call cygwin_select on them to be interruptible.
593 (cygwin_accept): Ditto.
594
0c8fe172
CF
5952003-06-02 Christopher Faylor <cgf@redhat.com>
596
597 * spawn.cc (spawn_guts): Don't hang around if the parent doesn't exist.
598
3786526e
CF
5992003-06-02 Christopher Faylor <cgf@redhat.com>
600
601 * cygthread.h (cygthread::terminate_thread): Mark private.
602 * cygthread.cc (cygthread::terminate_thread): Deallocate free_range
603 thread stuff.
604
cbdc3d17
CV
6052003-06-02 Corinna Vinschen <corinna@vinschen.de>
606
607 * fhandler_socket.cc (fhandler_socket::accept): Rename `signalled'
608 to `interrupted' as used in fhandler_socket::connect.
609
dfe7d288
CV
6102003-06-02 Corinna Vinschen <corinna@vinschen.de>
611
612 * fhandler_socket.cc (fhandler_socket::connect): Simplify previous
613 patch.
614 (fhandler_socket::accept): Ditto.
615
8e13bd14
CV
6162003-06-02 Corinna Vinschen <corinna@vinschen.de>
617
618 * fhandler_socket.cc: Include cygthread.h.
619 (class sock_event): Remove.
620 (thread_connect): New function.
621 (thread_accept): Ditto.
622 (fhandler_socket::connect): Use cygthread instead of socket event
623 handling for blocking sockets.
624 (fhandler_socket::accept): Ditto.
625
418c6236
CF
6262003-06-02 Christopher Faylor <cgf@redhat.com>
627
628 * fhandler.cc (fhandler_base::write): Correct minor printf formatting
629 style glitch.
630
c17e8306
PH
6312003-06-01 Pierre Humblet <pierre.humblet@ieee.org>
632
8e13bd14
CV
633 * fhandler_disk_file.cc (fhandler_disk_file::fstat_by_name): Assume
634 an existing directory is a root if FindFirstFile fails.
c17e8306 635
e59c6ff4
CF
6362003-05-30 Christopher Faylor <cgf@redhat.com>
637
638 * path.cc (mount_info::conv_to_win32_path): gcc warning about chroot_ok
639 was actually valid. Fix it.
640
cbe53754
CF
6412003-05-30 Christopher Faylor <cgf@redhat.com>
642
643 * cygheap.cc (init_cheap): Temporarily remove inline that newer gcc's
644 have problems with.
645
646 * path.cc (path_conv::check): Rework has_acls logic slightly. Uncouple
647 exec tests away from filesystem tests.
648
4aa10069
CV
6492003-05-30 Corinna Vinschen <corinna@vinschen.de>
650
651 * include/sys/param.h: Add DEV_BSIZE.
652
4e2db52c
CV
6532003-05-29 Pierre Humblet <pierre.humblet@ieee.org>
654 Corinna Vinschen <corinna@vinschen.de>
655
656 * fhandler_socket.cc (fhandler_socket::dup): Rearrange. Fix
657 conditional.
658
b666c2eb
CF
6592003-05-28 Christopher Faylor <cgf@redhat.com>
660
661 * mkvers.sh: Avoid "-dontuse" tags.
662
663 * path.cc (path_conv::check): Set exec state based on known situations.
664
665 * path.cc (mount_item::fnmunge): New function.
666 (mount_item::build_win32): New function.
667 (mount_info::conv_to_win32_path): Use build_win32 to build windows
668 path.
669 * path.h (mount_item::fnmunge): Declare new function.
4e2db52c 670 (mount_item::build_win32): Ditto.
b666c2eb
CF
671 * sys/mount.h (MOUNT_ENC): Define.
672
72c1470d
CV
6732003-05-28 Corinna Vinschen <corinna@vinschen.de>
674
675 * fhandler_socket.cc (fhandler_socket::dup): If running impersonated,
676 revert to original account before calling fixup_before_fork_exec
677 and impersonate again afterwards. Change comment accordingly.
678 Clean up error handling and debug output.
679
a946fb03
TP
6802003-05-27 Thomas Pfaff <tpfaff@gmx.net>
681
682 * fhandler_socket.cc (sock_event::~sock_event): New method.
683 (sock_event::load): Change to void. Check if winsock2 is available.
684 (socke_event::wait): Return 0 if interruptible mode is not available.
685 (fhandler_socket::connect): Remove checks for winsock2 availability.
686 (fhandler_socket::accept): Ditto.
687
dae86e45
CV
6882003-05-27 Corinna Vinschen <corinna@vinschen.de>
689
690 * fhandler_socket.cc (fhandler_socket::dup): First try duplicating
691 using WSADuplicateSocket/WSASocket, if that fails, try DuplicateHandle.
692
2311f6b0
CV
6932003-05-27 Bill C. Riemers <cygwin@docbill.net>
694
695 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Filter
49806b9b 696 permissions through umask on FAT or if ntsec is off.
2311f6b0 697
ada0376f
CV
6982003-05-26 Pierre Humblet <pierre.humblet@ieee.org>
699
700 * syscalls.cc (statfs): Call GetDiskFreeSpaceEx before GetDiskFreeSpace.
701
0372ad9f
CV
7022003-05-26 Corinna Vinschen <corinna@vinschen.de>
703
704 * fhandler.cc (is_at_eof): Fix conditional. Use INVALID_FILE_SIZE
705 instead of numeric constant.
706
6852f6c0
CV
7072003-05-26 Corinna Vinschen <corinna@vinschen.de>
708
709 * fhandler_socket.cc (fhandler_socket::connect): Guard calls to
710 sock_event methods by a check for WinSock2 availability.
711 (fhandler_socket::accept): Ditto.
712
fac297d5
CV
7132003-05-26 Corinna Vinschen <corinna@vinschen.de>
714
715 * fhandler.h: Rename FH_W95LSBUG flag to FH_LSEEKED.
716 (fhandler_base::set_did_lseek): Rename from set_check_win95_lseek_bug.
717 (fhandler_base::get_did_lseek): Rename from get_check_win95_lseek_bug.
718 (fhandler_base::set_fs_flags): New method.
719 (fhandler_base::get_fs_flags): Ditto.
720 * fhandler.cc (fhandler_base::write): Make 64 bit clean. Convert file
721 to a "sparse" file when writing after a long lseek (>64K) beyond EOF.
722 (fhandler_base::lseek): Call set_did_lseek() instead of
723 set_check_win95_lseek_bug().
724 (fhandler_base::fhandler_base): Initialize fs_flags to 0.
b6717153 725 * fhandler_disk_file.cc (fhandler_disk_file::open): Don't create files
fac297d5
CV
726 as "sparse" unconditionally. Set fs_flags member.
727
a80229fd
CV
7282003-05-25 Pierre Humblet <pierre.humblet@ieee.org>
729
730 * autoload.cc (GetDiskFreeSpaceEx): Add.
731 * syscalls.cc (statfs): Call full_path.root_dir() instead of
732 rootdir(full_path). Use GetDiskFreeSpaceEx when available and
733 report space available in addition to free space.
734 * fhandler_disk_file.cc (fhandler_disk_file::fstat_by_name):
735 Do not call FindFirstFile for disk root directories.
736
c295ce6f
CV
7372003-05-24 Joe Buehler <jhpb@draco.hekimian.com>
738
a80229fd 739 * fhandler_process.cc (format_process_stat): Use PagefileUsage
c295ce6f
CV
740 instead of VirtualSize.
741 (get_mem_values): Ditto.
742
5c768c97
CV
7432003-05-21 Corinna Vinschen <corinna@vinschen.de>
744
745 * shared_info.h: Match shared_name declaration with below change.
746 * shared.cc (shared_name): Use incoming char * parameter instead of
747 local static buffer.
293ce810 748 (open_shared): Accommodate new calling convention for shared_name.
5c768c97
CV
749 * exceptions.cc (events_init): Ditto.
750 * sigproc.cc (getsem): Ditto.
751 * syscalls.cc (login): Ditto.
752 (logout): Ditto.
753 (pututline): Ditto.
754
44be8197
CV
7552003-05-20 Corinna Vinschen <corinna@vinschen.de>
756
757 * fhandler_socket.cc (secret_event_name): Return void. Use incoming
5c768c97 758 char * parameter instead of local static buffer.
293ce810 759 (fhandler_socket::create_secret_event): Accommodate new calling
44be8197
CV
760 convention for secret_event_name.
761 (fhandler_socket::close_secret_event): Ditto.
762
d4f3ce31
CV
7632003-05-20 Corinna Vinschen <corinna@vinschen.de>
764
765 * fhandler_socket.cc (SECRET_EVENT_NAME): Remove.
766 (ENTROPY_SOURCE_NAME): Ditto.
767 (secret_event_name): New static function. Create shared event name
768 with "Global\" prefix on systems supporting terminal services.
769 (fhandler_socket::set_connect_secret): Fix conditional.
770 (fhandler_socket::create_secret_event): Create secret event using
771 secret_event_name().
772 (fhandler_socket::close_secret_event): Ditto.
773 * shared.cc (shared_name): Create shared object name with "Global\"
774 prefix on systems supporting terminal services.
775 * wincap.cc: Set has_terminal_services capability throughout.
776 (wincap_2003): New global object representing Windows 2003 Server
777 capabilities.
293ce810 778 (wincapc::init): Accommodate Windows 2003 Server.
d4f3ce31
CV
779 * wincap.h (struct wincaps): Add has_terminal_services capability.
780
10bada05
CV
7812003-05-20 Charles Wilson <cygwin@cwilson.fastmail.fm>
782
783 * winsup/cygwin/include/cygwin/version.h: Bump API minor version.
784 * winsup/cygwin/include/cygwin/types.h: Define key_t as long long.
785 * winsup/cygwin/cygwin.din: Add ftok, _ftok.
786 * winsup/cygwin/ipc.cc (ftok): Rework implementation.
787
d8ee8ca5
CF
7882003-05-18 Joe Buehler <jhpb@hekimian.com>
789
10bada05 790 * spawn.cc (spawn_guts): Show more of command line in strace output.
d8ee8ca5 791
c8fa3426
TP
7922003-05-15 Thomas Pfaff <tpfaff@gmx.net>
793
794 * thread.h (pthread::init_mainthread): Remove function parameter.
795 (MTinterface::Init): Ditto.
796 * thread.cc (MTinterface::Init): Remove function parameter.
797 Always initialize reent_key.
798 (pthread::init_mainthread): Remove function parameter.
799 (MTinterface::fixup_after_fork): Fix pthread::init_mainthread call.
800 * dcrt0.cc (dll_crt_0_1) Fix calls to MTinterface::Init and
801 pthread::init_mainthread.
802 Call pthread::init_mainthread only when not forked.
b6717153 803
f2669f5d
CV
8042003-05-15 Corinna Vinschen <corinna@vinschen.de>
805
806 * fhandler_proc.cc (format_proc_meminfo): Make swap memory output
807 Linux style values.
808
5d575f7d
CV
8092003-05-13 Corinna Vinschen <corinna@vinschen.de>
810
811 * include/cygwin/config.h: Define __USE_INTERNAL_STAT64 appropriately.
812
194d9eb3
CV
8132003-05-12 Corinna Vinschen <corinna@vinschen.de>
814
815 * Makefile.in (CYGWIN_START): Define as crt0.o. Add to TARGET_LIBS.
816 * fhandler.h (fhandler_virtual::fstat): Remove useless declaration.
817 * fhandler_virtual.cc: Remove _COMPILING_NEWLIB define.
818 * ipc.cc (ftok): Use stat64.
819 * syscalls.cc (_fstat64): Remove alias.
820 (_fstat): Ditto.
821 (_stat): Ditto.
822 (_fstat64_r): New function.
823 (_fstat_r): Ditto.
824 (_stat64_r): Ditto.
825 (stat_r): Ditto.
826 * crt0.o: New file, moved from newlib.
827 * include/sys/param.h: Ditto.
828 * include/sys/utime.h: Ditto.
829 * include/sys/utmp.h: Ditto.
830 * include/sys/dirent.h: Ditto. Expose different struct dirent,
831 dependening of the environment.
832
cc95baad
CV
8332003-05-11 Corinna Vinschen <corinna@vinschen.de>
834
835 Replace ino_t by __ino64_t throughout.
836
aee70853
CV
8372003-05-11 Corinna Vinschen <corinna@vinschen.de>
838
839 * include/cygwin/types.h: Add key_t typedef.
840
066ca06f
CF
8412003-05-10 Christopher Faylor <cgf@redhat.com>
842
843 * dir.cc (readdir): Fill out new old_d_ino field.
844 * fhandler.h (fhandler_base::namehash): Define as ino_t.
845 (fhandler_base::get_namehash): Ditto.
846 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Accommodate
847 new 64 bit st_ino.
848 * fhandler_socket.cc (fhandler_socket::fstat): Ditto.
849 * path.cc (hash_path_name): Return ino_t.
850 * syscalls.cc (stat64_to_stat32): Convert 64 bit inode to 32 bit.
851 * winsup.h (hash_path_name): Declare as returning ino_t.
852 * include/cygwin/stat.h (__stat32): Use 32 bit st_ino.
853 (__stat64): Use 64 bit st_ino.
854 * include/cygwin/types.h (__ino64_t): Define.
855 (__ino32_t): Ditto.
856 (ino_t): Define appropriately.
857
3e66a81c
CV
8582003-05-10 Corinna Vinschen <corinna@vinschen.de>
859
860 * Makefile.in (NEW_FUNCTIONS): All 32/64 from 0.79 API get
861 leading underscore.
862 * cygwin.din: Ditto.
863 * include/cygwin/version.h: Bump API minor number.
864
d3b450f3
CV
8652003-05-09 Corinna Vinschen <corinna@vinschen.de>
866
867 * include/cygwin/config.h: New file.
868
9508ebc5
CF
8692003-05-09 Christopher Faylor <cgf@redhat.com>
870
871 * cygthread.cc (cygthread::detach): Prioritize waiting for I/O
872 completion over waiting for signal delivery.
873
0bb7254f
TP
8742003-05-06 Thomas Pfaff <tpfaff@gmx.net>
875
876 * signal.cc (nanosleep): Do not wait twice for signal arrival.
877
a6d745f5
CV
8782003-05-03 Corinna Vinschen <corinna@vinschen.de>
879
880 * include/cygwin/types.h: Fix erroneous definition of ino_t from
881 2003-04-28.
882
40d3c804
CV
8832003-05-03 Corinna Vinschen <corinna@vinschen.de>
884
885 * syscalls.cc (chown_worker): Allow chown'ing of socket files.
886
2238537c
TP
8872003-04-30 Thomas Pfaff <tpfaff@gmx.net>
888
889 * Makefile.in: Revert patch from 2003-04-17.
890
6ef342e4
CF
8912003-04-28 Brian Ford <ford@vss.fsi.com>
892
893 * profil.h (PROFADDR): Prevent overflow when text segments are larger
894 than 256k.
895 * profil.c (profthr_func): Raise thread priority for more accurate
896 sampling.
897
8982003-04-26 Christopher Faylor <cgf@redhat.com>
899
900 * path.cc (hash_path_name): Use ino_t as type.
901
7d6d38aa
CF
9022003-04-26 Christopher Faylor <cgf@redhat.com>
903
904 * errno.cc (_sys_nerr): Fix compile error erroneously checked in on
905 2003-04-23.
906
f615d74b
CV
9072003-04-25 Corinna Vinschen <corinna@vinschen.de>
908
909 * include/netinet/ip.h: Include netinet/in_systm.h and netinet/in.h
910 to allow standalone usage (autoconf).
911
5d9a7c87
CF
9122003-04-23 Christopher Faylor <cgf@redhat.com>
913
914 * fork.cc: Change SLOW_PID_REUSE to NO_SLOW_PID_REUSE and invert ifdef
915 sense throughout.
916
0eaf24fe
CF
9172003-04-22 Christopher Faylor <cgf@redhat.com>
918
919 * select.cc (fhandler_pipe::ready_for_read): Assure that get_guard is
920 called for successful non-blocking pipe reads.
921
e8a57b4f
CV
9222003-04-22 Corinna Vinschen <corinna@vinschen.de>
923
924 * include/inttypes.h: New file.
925 * include/stdint.h: New file.
926 * include/cygwin/in.h: Include stdint.h instead of sys/types.h.
927 * include/cygwin/types.h: Include stdint.h. Remove typedefs for
928 intN_t and uintN_t since these are defined in stdint.h now.
929
99b1a40d
CF
9302003-04-21 Christopher Faylor <cgf@redhat.com>
931
650dc784 932 * include/cygwin/version.h: Bump DLL major number to 1005. Change DLL
99b1a40d
CF
933 minor number to 0. Bump API minor number.
934
beb54085
CV
9352003-04-20 Corinna Vinschen <corinna@vinschen.de>
936
937 * autoload.cc (CreateWindowStationA): Add.
938 (SetProcessWindowStation): Add.
939
6b3bdf38
CF
9402003-04-19 Christopher Faylor <cgf@redhat.com>
941
942 * wincap.h (wincaps:pty_needs_alloc_console): New element.
943 (wincapc:pty_needs_alloc_console): New function.
944 * wincap.cc: Add pty_needs_alloc_console throughout.
945 * fhandler_tty.cc (fhandler_tty_slave::open): Open an "invisible"
946 console on first pty allocation.
947
afa18d8a
CF
9482003-04-18 Christopher Faylor <cgf@redhat.com>
949
950 * fhandler_tty.cc (fhandler_tty_slave::open): Allocate a console
951 whenever a pty is allocated.
952
4e0d8778
CF
9532003-04-18 Christopher Faylor <cgf@redhat.com>
954
955 * Makefile.in: Use ${nostdlib} variable.
956
9572003-04-18 Diego Biurrun <diego@biurrun.de>
958
959 * fhandler_proc.cc (format_proc_cpuinfo): Change /proc/cpuinfo "vendor
960 id" string to "vendor_id" to conform with Linux systems.
961
4e837e73
CF
9622003-04-17 Christopher Faylor <cgf@redhat.com>
963
964 * syscalls.cc (setsid): Don't call FreeConsole if ctty is already < 0.
965
f3c1c540
TP
9662003-04-17 Thomas Pfaff <tpfaff@gmx.net>
967
968 * Makefile.in: Add finline-functions optimization to CXXFLAGS.
969 * autoload.cc (LoadDLLprime): Rename std_dll_init to
970 _std_dll_init.
971 (std_dll_init): Remove name mangling prototype. Add attributes
972 used and noinline.
973 (wsock_init): Ditto.
974 Change wsock_init to _wsock_init in wsock32 and ws2_32
975 LoadDLLprime.
976 * exceptions.cc (unused_sig_wrapper): Remove prototype. Add
977 attributes used and noinline.
978 * pwdgrp.h ((pwdgrp (passwd *&)): Remove inline code.
979 (pwdgrp (__group32 *&)): Ditto.
980 * grp.cc (pwdgrp (passwd *&)): Outline constructor.
981 (pwdgrp (__group32 *&)): Ditto.
982
a4cea440
TP
9832003-04-17 Thomas Pfaff <tpfaff@gmx.net>
984
985 * thread.h (pthread::equal): New static method.
986 * thread.cc: Rename pthread_equal to pthread::equal throughout.
987 (pthread_equal): Use pthread::equal to compare threads ids.
988
c448f78f
CF
9892003-04-15 Christopher Faylor <cgf@redhat.com>
990
991 * termios.cc (setspeed): New function.
992 (cfsetospeed): Use setspeed to set speed.
993 (cfsetispeed): Use setspeed to set speed.
994
9952003-04-15 Chris January <chris@atomice.net>
996
997 * autoload.cc: Add load statement for UuidCreate, and
998 UuidCreateSequential.
999 * cpuid.h: New file.
1000 * cygwin.din: Export gethostid.
1001 * fhandler_proc.cc (cpuid): Move to cpuid.h.
1002 (can_set_flag): Move to cpuid.h.
1003 * syscalls.cc (gethostid): New function.
5f92bef8 1004 * version.h: Bump api minor version number to 83.
c448f78f 1005
ffb576fb
TP
10062003-04-15 Thomas Pfaff <tpfaff@gmx.net>
1007
1008 * thread.h (pthread_rwlock::release): New method.
c448f78f
CF
1009 * thread.cc (pthread_rwlock::unlock): Use release to signal waiting
1010 threads.
ffb576fb
TP
1011 (pthread_rwlock::rdlock_cleanup): Signal waiting threads after a
1012 cancelation.
1013 (pthread_rwlock::wrlock_cleanup): Ditto.
1014
b3acb772
CF
10152003-04-13 Pierre Humblet <pierre.humblet@ieee.org>
1016
1017 * mkvers.sh: Prefix day with 0 in date only when day < 10.
1018
2e23862a
CV
10192003-04-11 Pierre Humblet <pierre.humblet@ieee.org>
1020
1021 * security.cc (get_info_from_sd): New function.
1022 (get_nt_attribute): Only call read_sd and get_info_from_sd.
1023 Return void.
1024 (get_file_attribute): Move sd error handling to get_info_from_sd.
1025 and symlink handling to fhandler_disk_file::fstat_helper.
1026 (get_nt_object_attribute): Only call read_sd and get_info_from_sd.
1027 Return void.
1028 (get_object_attribute): Remove symlink handling and simply return -1
1029 when ntsec is off.
1030 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): For
1031 symlinks set the attribute, call get_file_attribute to get the ids
1032 and return. In the normal case call get_file_attribute with the
1033 addresses of the buffer ids and do not recheck if the file is a socket.
1034
73afb2ab
CF
10352003-04-10 Christopher Faylor <cgf@redhat.com>
1036
1037 * cygthread.cc (cygthread::stub): Initialize stack pointer earlier.
1038 (cygthread::simplestub): Initialize stack pointer.
1039 (cygthread::terminate_thread): Account for possibility that stack
1040 pointer has not been set. Issue warnings for unusual conditions.
1041
2a1e8e11
CV
10422003-04-10 Corinna Vinschen <corinna@vinschen.de>
1043
1044 * regex/regex.h: Define regoff_t as _off_t.
1045 * regex/regex2.h: Ditto.
1046
ac5ec961
CV
10472003-04-10 Corinna Vinschen <corinna@vinschen.de>
1048
1049 * cygwin.din: Export wcscoll, wcswidth and wcwidth.
1050 * include/cygwin/version.h: Bump API minor number.
1051
e5d6d535
CF
10522003-04-10 Christopher Faylor <cgf@redhat.com>
1053
1054 * cygthread.h: Change 'avail' cygthread element to 'inuse' throughout.
1055 * cygthread.cc: Ditto.
1056 (cygthread::stub): Don't initialize already initialized events.
1057 (cygthread::freerange): Don't create thread here.
1058 (cygthread::cygthread): Create thread here. Die if thread not created.
1059 (cygthread::operator new): Simplify. Just grab a thread structure from
1060 the pool. Don't try to start the thread.
1061 (cygthread::terminate_thread): Don't close event handles. Just reuse
d8ee8ca5 1062 them. Call MEM_RELEASE rather than MEM_DECOMMIT (from Joe uehler).
e5d6d535 1063
ca81cd60
CF
10642003-04-08 Bob Cassels <bcassels@abinitio.com>
1065
1066 * fhandler_console.cc (fhandler_console::read) Handle certain key up
1067 events, to allow pasting accented characters and typing them using the
1068 "alt + numerics" sequences.
1069
10702003-04-07 Christopher Faylor <cgf@redhat.com>
1071
1072 * include/limits.h (IOV_MAX): Set to a number which is small enough to
1073 use in an array.
1074
b410f168
CF
10752003-04-04 Christopher Faylor <cgf@redhat.com>
1076
9dbe3289
CF
1077 * cygthread.h (cygthread::avail): Make LONG for easier use with
1078 Interlocked* functions.
1079 * cygthread.cc (cygthread::init): Eliminate unneeded muto.
1080 (cygthread::operator new): Don't lock. Instead change use of avail
1081 variable into tri-state: available (1), not available (-1),
1082 uninitialized (0).
1083 (cygthread::terminate_thread): Set avail to uninitialized.
1084 (cygthread::detach): Eliminate local 'avail'. Always set avail to 1
1085 unless signalled.
1086
10872003-04-04 Christopher Faylor <cgf@redhat.com>
1088
1089 * cygthread.cc (cygthread::operator new): Be more defensive when messing with
b410f168
CF
1090 threads that are marked "unavailable".
1091
a61bf8c3
CF
10922003-04-03 Christopher Faylor <cgf@redhat.com>
1093
1094 * fhandler_console.cc (CONVERT_LIMIT): Use a size for the 21st century.
1095
d5292d66
CV
10962003-04-03 Corinna Vinschen <corinna@vinschen.de>
1097
1098 * external.cc (check_ntsec): Return general ntsec state on NULL
1099 filename. Check wincap.is_security() additionally.
1100
5a87c616
CF
11012003-04-02 Christopher Faylor <cgf@redhat.com>
1102
1103 * Makefile.in (EXTRA_OFILES): Remove debugging object.
1104
d99c6176
CF
11052003-04-02 Jason Tishler <jason@tishler.net>
1106 Christopher Faylor <cgf@redhat.com>
1107
1108 * external.cc (check_ntsec): New function.
1109 (cygwin_internal): Add CW_CHECK_NTSEC handling to call check_ntsec()
1110 from applications.
1111 * include/cygwin/version.h: Bump API minor number.
1112 * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_CHECK_NTSEC.
1113
11142003-04-02 Christopher Faylor <cgf@redhat.com>
1115
1116 * cygthread.cc (cygthread::new): Add more defensive debugging.
1117
2d388e43 11182003-04-01 Pierre Humblet <pierre.humblet@ieee.org>
d99c6176 1119
2d388e43
CV
1120 * fhandler.cc (fhandler_base::fstat): Set the uid and gid fields
1121 from the current effective ids.
1122 * fhandler_socket.cc (fhandler_socket::fstat): Keep the uid and gid set
1123 by fhandler_base::fstat.
1124 * security.cc (get_nt_attribute): Do not test wincap.has_security ().
1125 (get_nt_object_attribute): Ditto.
1126 (get_file_attribute): Add test for wincap.has_security ().
1127 (get_object_attribute): Ditto.
1128
1727fba0
CV
11292003-04-01 Corinna Vinschen <corinna@vinschen.de>
1130
1131 * dir.cc: Change __off32_t to _off_t and __off64_t to _off64_t
1132 throughout.
1133 * fhandler.cc: Ditto.
1134 * fhandler.h: Ditto.
1135 * fhandler_clipboard.cc: Ditto.
1136 * fhandler_disk_file.cc: Ditto.
1137 * fhandler_dsp.cc: Ditto.
1138 * fhandler_floppy.cc: Ditto.
1139 * fhandler_mem.cc: Ditto.
1140 * fhandler_proc.cc: Ditto.
1141 * fhandler_process.cc: Ditto.
1142 * fhandler_random.cc: Ditto.
1143 * fhandler_registry.cc: Ditto.
1144 * fhandler_tape.cc: Ditto.
1145 * fhandler_termios.cc: Ditto.
1146 * fhandler_virtual.cc: Ditto.
1147 * fhandler_zero.cc: Ditto.
1148 * mmap.cc: Ditto.
1149 * pipe.cc: Ditto.
1150 * syscalls.cc: Ditto.
1151 * winsup.h: Ditto.
1152 * include/cygwin/stat.h: Ditto.
1153 * include/cygwin/types.h: Ditto. Remove definition of __off32_t
1154 and __off64_t.
1155
333879e7
CF
11562003-03-31 Christopher Faylor <cgf@redhat.com>
1157
1158 * exceptions.cc (setup_handler): Make sure winapi lock is released when
1159 exiting loop.
1160
a2105d93
CF
11612003-03-30 Christopher Faylor <cgf@redhat.com>
1162
1163 * include/cygwin/fs.h: Remove unneeded include.
1164 * include/cygwin/in.h: Include sys/types.h rather than cygwin/types.h.
1165
856a9750
CV
11662003-03-29 Corinna Vinschen <corinna@vinschen.de>
1167
1168 * syscalls.cc (login): Fix comment.
1169 (logout): Ditto.
1170
8304de2e
CV
11712003-03-29 Corinna Vinschen <corinna@vinschen.de>
1172
1173 * syscalls.cc: Slightly cleanup all utmp functions.
1174 (login): Use mutex to secure against concurrent access to wtmp file.
1175 (logout): Rewrite using POSIX calls.
1176 (utmp_fd): Initialized to -1 now. Any value < 0 is treated as closed
1177 in subsequent functions.
1178 (utmp_readonly): New variable, indicating utmp file open for reading
1179 only.
1180 (internal_setutent): New function implementing setutent().
1181 (setutent): Call internal_setutent now.
1182 (endutent): Reset utmp_readonly.
1183 (getutent): Return immediately if utmp file can't be opened.
1184 (getutid): Ditto.
1185 (getutline): Ditto.
1186 (pututline): Ditto. Use mutex to secure against concurrent access to
1187 utmp file.
1188
46c8214c
CF
11892003-03-28 Christopher Faylor <cgf@redhat.com>
1190
1191 * Makefile.in: Remove EXE_LDFLAGS. Fix fhandler_CFLAGS typo. Recognize .s suffix.
1192 * configure.in: Remove EXE_LDFLAGS.
1193 * configure: Regenerate.
1194
a7ab35c1
CF
11952003-03-28 Christopher Faylor <cgf@redhat.com>
1196
1197 * include/sys/cygwin.h: Declare cygwin_internal as unsigned long.
1198 * external.cc (cygwin_internal): Define as unsigned long.
1199
12002003-03-27 Christopher Faylor <cgf@redhat.com>
1201
1202 * include/sys/cygwin.h: Move cygwin_internal outside of WINVER
1203 conditional.
1204
eff6c00e
TP
12052003-03-27 Thomas Pfaff <tpfaff@gmx.net>
1206
1207 * thread.cc: Change 1==foo equations to foo==1 throughout.
1208
15648790
TP
12092003-03-27 Thomas Pfaff <tpfaff@gmx.net>
1210
1211 * thread.h: Change class names, methods, members and local vars
1212 according to the GNU coding style.
1213 * thread.cc: Ditto.
1214 * dcrt0.cc (dll_crt0_1): Rename pthread::initMainThread call to
1215 pthread::init_mainthread.
1216 * pthread.cc (pthead_getsequence_np): Rename pthread::isGoodObject
1217 call to pthread::is_good_object.
1218
98b36ec8
CV
12192003-03-27 Joe Buehler <jhpb@draco.hekimian.com>
1220
1ce82d24
CF
1221 * autoload.cc: Add RegGetKeySecurity().
1222 * security.cc (get_nt_object_attribute): Use RegGetKeySecurity() for
98b36ec8
CV
1223 performance.
1224
85738bf7
CF
12252003-03-25 Christopher Faylor <cgf@redhat.com>
1226 Joe Buehler <jhpb@draco.hekimian.com>
1227
1228 * fork.cc (fork_parent): Don't copy signals from parent to child here.
1229 * sigproc.cc (proc_subproc): Copy signals from parent to child pinfo
1230 here.
1231
9306ba2e
TP
12322003-03-23 Thomas Pfaff <tpfaff@gmx.net>
1233
85738bf7
CF
1234 * thread.h (class List): Move inline code inside class declaration.
1235 (List::forEach): Change callback parameter to template class member
1236 function pointer.
1237 (pthread_keys::fixup_before_fork): Change to inline. Use List::forEach
1238 to fixup keys.
9306ba2e
TP
1239 (pthread_keys::fixup_after_fork): Ditto.
1240 (pthread_keys::runAllDestructors): Ditto.
1241 (pthread_key::saveAKey): Remove.
1242 (pthread_key::restoreAKey): Ditto.
1243 (pthread_key::destroyAKey): Ditto.
1244 (pthread_key::run_destructor): Rename to runDestructor.
85738bf7
CF
1245 (pthread_mutex::fixup_after_fork): Change to inline. Use List::forEach
1246 to fixup mutexes after a fork.
9306ba2e
TP
1247 (pthread_mutex::FixupAfterFork): New method.
1248 (pthread_mutex::mutexes): New member.
85738bf7
CF
1249 (pthread_cond::fixup_after_fork): Change to inline. Use List::forEach
1250 to fixup conds after a fork.
9306ba2e
TP
1251 (pthread_cond::FixupAfterFork): New method.
1252 (pthread_cond::conds): New member.
85738bf7 1253 (pthread_rwlock::fixup_after_fork): Change to inline. Use
9306ba2e
TP
1254 List::forEach to fixup rwlocks after a fork.
1255 (pthread_rwlock::FixupAfterFork): New method.
1256 (pthread_rwlock::rwlocks): New member.
85738bf7
CF
1257 (semaphore::fixup_after_fork): Change to inline. Use List::forEach to
1258 fixup mutexes after a fork.
9306ba2e
TP
1259 (semaphore::FixupAfterFork): New method.
1260 (semaphore::semaphores): New member.
1261 (MTinterface::mutexs): Remove.
1262 (MTinterface::conds): Ditto.
1263 (MTinterface::rwlocks): Ditto.
1264 (MTinterface::semaphores): Ditto.
1265 (pthread_equal): Add extern "C".
1266 (pthread_mutex_lock): Ditto.
85738bf7
CF
1267
1268 * thread.cc (MTinterface::fixup_after_fork): Change fixup_after_fork
1269 calls for pthread objects.
9306ba2e 1270 (semaphore::conds): Instantiate.
85738bf7
CF
1271 (pthread_cond::pthread_cond): Use List::Insert rather than custom list
1272 code.
1273 (pthread_cond::~pthread_cond): Use List::Remove rather than custom list
1274 code.
9306ba2e
TP
1275 (pthread_cond::fixup_after_fork): Rename to FixupAfterFork.
1276 (pthread_rwlock::rwlocks): Instantiate.
85738bf7
CF
1277 (pthread_rwlock::pthread_crwlock): Use List::Insert rather than custom
1278 list code.
1279 (pthread_rwlock::~pthread_rwlock): Use List::Remove rather than custom
1280 list code.
9306ba2e
TP
1281 (pthread_rwlock::fixup_after_fork): Rename to FixupAfterFork.
1282 (pthread_key::saveAKey): Remove.
1283 (pthread_key::fixup_before_fork): Ditto.
1284 (pthread_key::restoreAKey): Ditto.
1285 (pthread_key::fixup_after_fork): Ditto.
1286 (pthread_key::destroyAKey): Ditto.
1287 (pthread_key::runAllDestructors): Ditto.
1288 (pthread_key::run_destructor): Rename to runDestructor.
1289 (pthread_mutex::mutexes): Instantiate.
85738bf7
CF
1290 (pthread_mutex::pthread_mutex): Use List::Insert rather than custom
1291 list code.
1292 (pthread_mutex::~pthread_mutex): Use List::Remove rather than custom
1293 list code.
9306ba2e
TP
1294 (pthread_mutex::fixup_after_fork): Rename to FixupAfterFork.
1295 (semaphore::conds): Instantiate.
85738bf7
CF
1296 (semaphore::semaphore): Use List::Insert rather than custom list code.
1297 (semaphores::~semaphore): Use List::Remove rather than custom list
9306ba2e 1298 code.
9306ba2e
TP
1299 (semaphore::fixup_after_fork): Rename to FixupAfterFork.
1300
ff3ef36d
CF
13012003-03-22 Christopher Faylor <cgf@redhat.com>
1302
1303 * pipe.cc (fhandler_pipe::dup): Don't dup input_handle if it doesn't
1304 exist.
1305
ca04f61f
CF
13062003-03-22 Christopher Faylor <cgf@redhat.com>
1307
1308 * syscalls.cc (unlink): Be more defensive when SetFileAttributes is
1309 called. Fix typo in debugging output.
1310
89e7a1ce
CF
13112003-03-21 Christopher Faylor <cgf@redhat.com>
1312
1313 * fork.cc: Conditionalize use of slow_pid_reuse throughout. It's not
1314 necessary for newer versions of bash.
1315
fa85038b
CV
13162003-03-20 Corinna Vinschen <corinna@vinschen.de>
1317
1318 * fhandler_socket.cc (fhandler_socket::sendto): Restrict EPIPE and
1319 SIGPIPE handling to connection oriented sockets. Add comment.
1320
4da34970
CF
13212003-03-19 Christopher Faylor <cgf@redhat.com>
1322
1323 * sigproc.h (signal_fixup_after_exec): Eliminate argument in declaration.
1324 * exceptions.cc (signal_fixup_after_exec): Eliminate argument in
1325 definition. Don't reset signal handlers after spawm. Just treat like
1326 fork/exec.
1327 * dcrt0.cc (dll_crt0_1): Don't pass PROC_SPAWN argument to
1328 signal_fixup_after_exec.
1329 * syscalls.cc (unlink): Don't change attributes of file if not readonly/system.
1330 Ditto for resetting of arguments.
1331
036ac6b3
CV
13322003-03-19 Corinna Vinschen <corinna@vinschen.de>
1333
1334 * glob.c: Eliminate __INSIDE_CYGWIN__ preprocessor conditionals
1335 throughout.
1336
b1897d27
CV
13372003-03-19 Corinna Vinschen <corinna@vinschen.de>
1338
1339 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Fix
1340 wrong usage of S_IFDIR.
1341 * security.cc (get_attribute_from_acl): Ditto.
1342 (get_file_attribute): Fix wrong usage of S_IFLNK.
1343 (get_object_attribute): Ditto.
1344 (alloc_sd): Fix wrong usage of S_IFDIR.
1345 * syscalls.cc (chmod): Allow chmod'ing of socket files.
1346
c16d0946
CV
13472003-03-19 Corinna Vinschen <corinna@vinschen.de>
1348
1349 * include/cygwin/version.h (CYGWIN_VERSION_CHECK_FOR_USING_BIG_TYPES):
1350 Define.
1351 * glob.c (g_lstat): Use CYGWIN_VERSION_CHECK_FOR_USING_BIG_TYPES
1352 instead of numerical constants.
1353 (g_stat): Ditto.
1354
6a80a133
TP
13552003-03-18 Thomas Pfaff <tpfaff@gmx.net>
1356
1357 * pthread.cc (pthread_attr_init): Remove
1358 (pthread_attr_destroy): Ditto.
1359 (pthread_attr_setdetachstate): Ditto.
1360 (pthread_attr_getdetachstate): Ditto.
1361 (pthread_attr_setstacksize): Ditto.
1362 (pthread_attr_getstacksize): Ditto.
1363 (pthread_attr_setinheritsched): Ditto.
1364 (pthread_attr_getinheritsched): Ditto.
1365 (pthread_attr_setschedparam): Ditto.
1366 (pthread_attr_getschedparam): Ditto.
1367 (pthread_attr_setschedpolicy): Ditto.
1368 (pthread_attr_getschedpolicy): Ditto.
1369 (pthread_attr_setscope): Ditto.
1370 (pthread_attr_getscope): Ditto.
1371 (pthread_attr_setstackaddr): Ditto.
1372 (pthread_attr_getstackaddr): Ditto.
1373 (pthread_key_create): Ditto.
1374 (pthread_key_delete): Ditto.
1375 (pthread_setspecific): Ditto.
1376 (pthread_getspecific): Ditto.
1377 (pthread_kill): Ditto.
1378 (pthread_sigmask): Ditto.
1379 (pthread_equal): Ditto.
1380 (pthread_mutex_lock): Ditto.
1381 (pthread_mutex_trylock): Ditto.
1382 (pthread_mutex_unlock): Ditto.
1383 (pthread_mutex_destroy): Ditto.
1384 (pthread_mutex_setprioceiling): Ditto.
1385 (pthread_mutex_getprioceiling): Ditto.
1386 (pthread_mutexattr_destroy): Ditto.
1387 (pthread_mutexattr_getprioceiling): Ditto.
1388 (pthread_mutexattr_getprotocol): Ditto.
1389 (pthread_mutexattr_getpshared): Ditto.
1390 (pthread_mutexattr_gettype): Ditto.
1391 (pthread_mutexattr_init): Ditto.
1392 (pthread_mutexattr_setprioceiling): Ditto.
1393 (pthread_mutexattr_setprotocol): Ditto.
1394 (pthread_mutexattr_setpshared): Ditto.
1395 (pthread_mutexattr_settype): Ditto.
1396 (pthread_cond_destroy): Ditto.
1397 (pthread_cond_signal): Ditto.
1398 (pthread_cond_broadcast): Ditto.
1399 (pthread_condattr_init): Ditto.
1400 (pthread_condattr_destroy): Ditto.
1401 (pthread_condattr_getpshared): Ditto.
1402 (pthread_condattr_setpshared): Ditto.
1403 (pthread_rwlock_destroy): Ditto.
1404 (pthread_rwlock_rdlock): Ditto.
1405 (pthread_rwlock_tryrdlock): Ditto.
1406 (pthread_rwlock_wrlock): Ditto.
1407 (pthread_rwlock_trywrlock): Ditto.
1408 (pthread_rwlock_unlock): Ditto.
1409 (pthread_rwlockattr_init): Ditto.
1410 (pthread_rwlockattr_getpshared): Ditto.
1411 (pthread_rwlockattr_setpshared): Ditto.
1412 (pthread_rwlockattr_destroy): Ditto.
1413 (pthread_getconcurrency): Ditto.
1414 (pthread_setconcurrency): Ditto.
1415 (pthread_getschedparam): Ditto.
1416 (pthread_setschedparam): Ditto.
1417
1418 * thread.h (__pthread_attr_init): Remove prototype.
1419 (__pthread_attr_destroy): Ditto.
1420 (__pthread_attr_setdetachstate): Ditto.
1421 (__pthread_attr_getdetachstate): Ditto.
1422 (__pthread_attr_setstacksize): Ditto.
1423 (__pthread_attr_getstacksize): Ditto.
1424 (__pthread_attr_setinheritsched): Ditto.
1425 (__pthread_attr_getinheritsched): Ditto.
1426 (__pthread_attr_setschedparam): Ditto.
1427 (__pthread_attr_getschedparam): Ditto.
1428 (__pthread_attr_setschedpolicy): Ditto.
1429 (__pthread_attr_getschedpolicy): Ditto.
1430 (__pthread_attr_setscope): Ditto.
1431 (__pthread_attr_getscope): Ditto.
1432 (__pthread_attr_setstackaddr): Ditto.
1433 (__pthread_attr_getstackaddr): Ditto.
1434 (__pthread_key_create): Ditto.
1435 (__pthread_key_delete): Ditto.
1436 (__pthread_setspecific): Ditto.
1437 (__pthread_getspecific): Ditto.
1438 (__pthread_kill): Ditto.
1439 (__pthread_sigmask): Ditto.
1440 (__pthread_equal): Ditto.
1441 (__pthread_mutex_lock): Ditto.
1442 (__pthread_mutex_trylock): Ditto.
1443 (__pthread_mutex_unlock): Ditto.
1444 (__pthread_mutex_destroy): Ditto.
1445 (__pthread_mutex_setprioceiling): Ditto.
1446 (__pthread_mutex_getprioceiling): Ditto.
1447 (__pthread_mutexattr_destroy): Ditto.
1448 (__pthread_mutexattr_getprioceiling): Ditto.
1449 (__pthread_mutexattr_getprotocol): Ditto.
1450 (__pthread_mutexattr_getpshared): Ditto.
1451 (__pthread_mutexattr_gettype): Ditto.
1452 (__pthread_mutexattr_init): Ditto.
1453 (__pthread_mutexattr_setprioceiling): Ditto.
1454 (__pthread_mutexattr_setprotocol): Ditto.
1455 (__pthread_mutexattr_setpshared): Ditto.
1456 (__pthread_mutexattr_settype): Ditto.
1457 (__pthread_cond_destroy): Ditto.
1458 (__pthread_cond_signal): Ditto.
1459 (__pthread_cond_broadcast): Ditto.
1460 (__pthread_condattr_init): Ditto.
1461 (__pthread_condattr_destroy): Ditto.
1462 (__pthread_condattr_getpshared): Ditto.
1463 (__pthread_condattr_setpshared): Ditto.
1464 (__pthread_rwlock_destroy): Ditto.
1465 (__pthread_rwlock_rdlock): Ditto.
1466 (__pthread_rwlock_tryrdlock): Ditto.
1467 (__pthread_rwlock_wrlock): Ditto.
1468 (__pthread_rwlock_trywrlock): Ditto.
1469 (__pthread_rwlock_unlock): Ditto.
1470 (__pthread_rwlockattr_init): Ditto.
1471 (__pthread_rwlockattr_getpshared): Ditto.
1472 (__pthread_rwlockattr_setpshared): Ditto.
1473 (__pthread_rwlockattr_destroy): Ditto.
1474 (__pthread_getconcurrency): Ditto.
1475 (__pthread_setconcurrency): Ditto.
1476 (__pthread_getschedparam): Ditto.
1477 (__pthread_setschedparam): Ditto.
1478
1479 * thread.cc: Rename __pthread_equal to pthread_equal throughout.
1480 Change pthread_self parameter appropriate.
1481 (__pthread_attr_init): Remove __ prefix. Change to extern "C".
1482 (__pthread_attr_destroy): Ditto.
1483 (__pthread_attr_setdetachstate): Ditto.
1484 (__pthread_attr_getdetachstate): Ditto.
1485 (__pthread_attr_setstacksize): Ditto.
1486 (__pthread_attr_getstacksize): Ditto.
1487 (__pthread_attr_setinheritsched): Ditto.
1488 (__pthread_attr_getinheritsched): Ditto.
1489 (__pthread_attr_setschedparam): Ditto.
1490 (__pthread_attr_getschedparam): Ditto.
1491 (__pthread_attr_setschedpolicy): Ditto.
1492 (__pthread_attr_getschedpolicy): Ditto.
1493 (__pthread_attr_setscope): Ditto.
1494 (__pthread_attr_getscope): Ditto.
1495 (__pthread_attr_setstackaddr): Ditto.
1496 (__pthread_attr_getstackaddr): Ditto.
1497 (__pthread_key_create): Ditto.
1498 (__pthread_key_delete): Ditto.
1499 (__pthread_setspecific): Ditto.
1500 (__pthread_getspecific): Ditto.
1501 (__pthread_kill): Ditto.
1502 (__pthread_sigmask): Ditto.
1503 (__pthread_equal): Ditto.
1504 (__pthread_mutex_lock): Ditto.
1505 (__pthread_mutex_trylock): Ditto.
1506 (__pthread_mutex_unlock): Ditto.
1507 (__pthread_mutex_destroy): Ditto.
1508 (__pthread_mutex_setprioceiling): Ditto.
1509 (__pthread_mutex_getprioceiling): Ditto.
1510 (__pthread_mutexattr_destroy): Ditto.
1511 (__pthread_mutexattr_getprioceiling): Ditto.
1512 (__pthread_mutexattr_getprotocol): Ditto.
1513 (__pthread_mutexattr_getpshared): Ditto.
1514 (__pthread_mutexattr_gettype): Ditto.
1515 (__pthread_mutexattr_init): Ditto.
1516 (__pthread_mutexattr_setprioceiling): Ditto.
1517 (__pthread_mutexattr_setprotocol): Ditto.
1518 (__pthread_mutexattr_setpshared): Ditto.
1519 (__pthread_mutexattr_settype): Ditto.
1520 (__pthread_cond_destroy): Ditto.
1521 (__pthread_cond_signal): Ditto.
1522 (__pthread_cond_broadcast): Ditto.
1523 (__pthread_condattr_init): Ditto.
1524 (__pthread_condattr_destroy): Ditto.
1525 (__pthread_condattr_getpshared): Ditto.
1526 (__pthread_condattr_setpshared): Ditto.
1527 (__pthread_rwlock_destroy): Ditto.
1528 (__pthread_rwlock_rdlock): Ditto.
1529 (__pthread_rwlock_tryrdlock): Ditto.
1530 (__pthread_rwlock_wrlock): Ditto.
1531 (__pthread_rwlock_trywrlock): Ditto.
1532 (__pthread_rwlock_unlock): Ditto.
1533 (__pthread_rwlockattr_init): Ditto.
1534 (__pthread_rwlockattr_getpshared): Ditto.
1535 (__pthread_rwlockattr_setpshared): Ditto.
1536 (__pthread_rwlockattr_destroy): Ditto.
1537 (__pthread_getconcurrency): Ditto.
1538 (__pthread_setconcurrency): Ditto.
1539 (__pthread_getschedparam): Ditto.
1540 (__pthread_setschedparam): Ditto.
1541
00d296a3
TP
15422003-03-18 Thomas Pfaff <tpfaff@gmx.net>
1543
1544 * cygwin.din: Add pthread_rwlock_destroy, pthread_rwlock_init,
1545 pthread_rwlock_rdlock, pthread_rwlock_tryrdlock,
1546 pthread_rwlock_wrlock, pthread_rwlock_trywrlock,
1547 pthread_rwlock_unlock, pthread_rwlockattr_init,
1548 pthread_rwlockattr_getpshared, pthread_rwlockattr_setpshared,
1549 and pthread_rwlockattr_destroy.
1550 * include/cygwin/version.h: Bump API minor number.
1551 * include/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Define a
1552 reasonable value.
1553 Add prototypes for pthread_rwlock_destroy, pthread_rwlock_init,
1554 pthread_rwlock_rdlock, pthread_rwlock_tryrdlock,
1555 pthread_rwlock_wrlock, pthread_rwlock_trywrlock,
1556 pthread_rwlock_unlock, pthread_rwlockattr_init,
1557 pthread_rwlockattr_getpshared, pthread_rwlockattr_setpshared,
1558 and pthread_rwlockattr_destroy.
1559 * thread.h (PTHREAD_ONCE_MAGIC): Remove superflous semicolon.
1560 (PTHREAD_RWLOCK_MAGIC): New define.
1561 (PTHREAD_RWLOCKATTR_MAGIC): Ditto.
1562 (pthread_rwlockattr): New class.
1563 (pthread_rwlock): Ditto.
1564 (MTinterface::rwlocks): New member.
1565 (MTinterface::MTinterface): Initialize rwlocks.
1566 Add prototypes for __pthread_rwlock_destroy,
1567 __pthread_rwlock_wrlock, __pthread_rwlock_trywrlock,
1568 __pthread_rwlock_unlock, __pthread_rwlockattr_init,
1569 __pthread_rwlockattr_getpshared, __pthread_rwlockattr_setpshared,
1570 and __pthread_rwlockattr_destroy.
1571 * thread.cc (MTinterface::Init): Initialize rwlock internal mutex.
1572 (MTinterface::fixup_after_fork): Fixup rwlocks after fork.
1573 (pthread_rwlockattr::isGoodObject): Implement.
1574 (pthread_rwlockattr::pthread_rwlockattr): Ditto.
1575 (pthread_rwlockattr::~pthread_rwlockattr): Ditto.
1576 (pthread_rwlock::initMutex): Ditto.
1577 (pthread_rwlock::pthread_rwlock): Ditto.
1578 (pthread_rwlock::~pthread_rwlock): Ditto.
1579 (pthread_rwlock::RdLock): Ditto.
1580 (pthread_rwlock::TryRdLock): Ditto.
1581 (pthread_rwlock::WrLock): Ditto.
1582 (pthread_rwlock::TryWrLock): Ditto.
1583 (pthread_rwlock::UnLock): Ditto.
1584 (pthread_rwlock::addReader): Ditto.
1585 (pthread_rwlock::removeReader): Ditto.
1586 (pthread_rwlock::lookupReader): Ditto.
1587 (pthread_rwlock::RdLockCleanup): Ditto.
1588 (pthread_rwlock::WrLockCleanup): Ditto.
1589 (pthread_rwlock::fixup_after_fork): Ditto.
1590 (pthread_rwlock::isGoodObject): Ditto.
1591 (pthread_rwlock::isGoodInitializer): Ditto.
1592 (pthread_rwlock::isGoodInitializerOrObject): Ditto.
1593 (pthread_rwlock::isGoodInitializerOrBadObject): Ditto.
1594 (__pthread_rwlock_destroy): Ditto.
1595 (pthread_rwlock::init): Ditto.
1596 (__pthread_rwlock_rdlock): Ditto.
1597 (__pthread_rwlock_tryrdlock): Ditto.
1598 (__pthread_rwlock_wrlock): Ditto.
1599 (__pthread_rwlock_trywrlock): Ditto.
1600
f592b05d
TP
16012003-03-18 Thomas Pfaff <tpfaff@gmx.net>
1602
1603 * thread.h (pthread_cond::ExitingWait): Remove.
1604 (pthread_cond::mutex): Ditto.
1605 (pthread_cond::cond_access): Ditto.
1606 (pthread_cond::win32_obj_id): Ditto.
1607 (pthread_cond::TimedWait): Ditto.
1608 (pthread_cond::BroadCast): Ditto.
1609 (pthread_cond::Signal): Ditto.
1610 (pthread_cond::waiting): Change type to unsigned long.
1611 (pthread_cond::pending): New member.
1612 (pthread_cond::semWait): Ditto.
1613 (pthread_cond::mtxIn): Ditto.
1614 (pthread_cond::mtxOut): Ditto.
1615 (pthread_cond::mtxCond): Ditto.
1616 (pthread_cond::UnBlock): New method.
1617 (pthread_cond::Wait): Ditto.
1618 * thread.cc: Update list of cancellation points.
1619 (pthread_cond::pthread_cond): Rewrite.
1620 (pthread_cond::~pthread_cond): Ditto.
1621 (pthread_cond::TimedWait): Remove.
1622 (pthread_cond::BroadCast): Ditto.
1623 (pthread_cond::Signal): Ditto.
1624 (pthread_cond::UnBlock): Implement.
1625 (pthread_cond::Wait): Ditto.
1626 (pthread_cond::fixup_after_fork): Rewrite.
1627 (pthread_mutex::fixup_after_fork): Remove DETECT_BAD_APP
1628 conditional.
1629 (__pthread_cond_broadcast): Just return 0 if the condition is
1630 not initialized. Call pthread_cond::UnBlock to release blocked
1631 threads.
1632 (__pthread_cond_signal): Ditto.
1633 (__pthread_cond__dowait): Rewrite.
1634 (pthread_cond_timedwait): Add pthread_testcancel call. Fix
1635 waitlength calculation.
1636 (pthread_cond_wait): Add pthread_testcancel call.
1637
2ff03dc2
TP
16382003-03-18 Thomas Pfaff <tpfaff@gmx.net>
1639
1640 * include/pthread.h (PTHREAD_MUTEX_NORMAL): New define.
1641 * thread.cc: Remove errno.h include.
1642 (pthread::precreate): Change internal mutex type to normal.
1643 (pthread_mutex::canBeUnlocked): Implement.
1644 (pthread_mutex::pthread_mutex): Initialize lock_counter with 0.
1645 (pthread_mutex::Lock): Rename to _Lock. Add self parameter.
1646 Change lock_counter logic. Update SetOwner call.
1647 (pthread_mutex::TryLock): Rename to _TryLock. Add self parameter.
1648 Change lock_counter logic. Update SetOwner call.
1649 (pthread_mutex::UnLock): Rename to _UnLock. Add self parameter.
1650 Change lock_counter logic.
1651 (pthread_mutex::Destroy): Rename to _Destroy. Update TryLock call.
1652 (pthread_mutex::SetOwner): Move to thread.h as inline.
1653 (pthread_mutex::LockRecursive): Ditto.
1654 (pthread_mutex::fixup_after_fork): Change lock_counter logic.
1655 (__pthread_mutexattr_settype): Add PTHREAD_MUTEX_NORMAL to valid
1656 types check.
1657 * thread.h: Include errno.h and limits.h.
1658 (MUTEX_LOCK_COUNTER_INITIAL): Remove.
1659 (MUTEX_OWNER_ANONYMOUS): New define.
1660 (pthread_mutex::canBeUnlocked): New static method.
1661 (pthread_mutex::lock_counter): Change type to unsigned long.
1662 (pthread_mutex::GetPthreadSelf): New method.
1663 (pthread_mutex::Lock): Call _Lock with pthread_self pointer.
1664 (pthread_mutex::TryLock): Call _TryLock with pthread_self pointer.
1665 (pthread_mutex::UnLock): Call _UnLock with pthread_self pointer.
1666 (pthread_mutex::Destroy): Call _Destroy with pthread_self pointer.
1667 (pthread_mutex::SetOwner): Moved from thread.cc as inline.
1668 (pthread_mutex::LockRecursive): Ditto.
1669 (pthread_mutex::_Lock): New method.
1670 (pthread_mutex::_TryLock): New method.
1671 (pthread_mutex::_UnLock): New method.
1672 (pthread_mutex::_Destroy): New method.
1673
dcd350f0
CV
16742003-03-18 Christopher January <chris@atomice.net>
1675
1676 * fhandler_proc.cc (format_proc_cpuinfo): Use IsProcessorFeaturePresent
1677 only on Windows NT. Read CPU Mhz value only on NT. Revert previous
1678 change so cpuid instruction is called even on non-NT systems.
1679
c51dc9c2
CV
16802003-03-17 Corinna Vinschen <corinna@vinschen.de>
1681
a2105d93 1682 * glob.c (g_lstat): Change API minor test to match API minor number
c51dc9c2
CV
1683 change in previous patch.
1684 (g_stat): Ditto.
1685
f194ba1f
CF
16862003-03-17 Christopher Faylor <cgf@redhat.com>
1687
1688 * include/cygwin/version.h: Reorganize last two api versions so that
1689 btowc and trunc exports show up before previous bump since there has
1690 been no exported version of the DLL with the 64 bit changes yet but
1691 1.3.22 will have the btowc and trunc.
1692
3543669f
CF
16932003-03-17 Christopher Faylor <cgf@redhat.com>
1694
1695 * cygwin.din: Export btowc, trunc.
1696 * include/cygwin/version.h: Reflect new exports.
1697 * syscalls.cc (_stat): Rename to stat to avoid newlib wrapper.
1698 * syscalls.cc (_fstat): Ditto.
1699
17002003-03-16 Christopher Faylor <cgf@redhat.com>
1701
1702 * fhandler_console.cc (fhandler_console::close): Correct check for
1703 current tty. Add debugging output when console is freed.
1704 (set_console_state_for_spawn): Add debugging output.
1705 * fhandler_tty.cc (fhandler_tty_slave::open): Don't decrement console
1706 open flag when vforking.
1707 * sigproc.cc (sigproc_terminate): Fix debugging output.
1708 * spawn.cc (handle): Eliminate second argument.
1709 (spawn_guts): Reflect elimination of argument change to handle.
1710 * syscalls.cc (setsid): Add debugging output when console is freed.
1711
17122003-03-14 Christopher Faylor <cgf@redhat.com>
1713
1714 * syscalls.cc (rename): Revert assumption that DELETE_ON_CLOSE works on
1715 Win9x.
1716
41ffdfa5
CF
17172003-03-13 Christopher Faylor <cgf@redhat.com>
1718
1719 * include/cygwin/version.h: Bump DLL minor number to 23.
1720
5b186cd9
CV
17212003-03-13 Corinna Vinschen <corinna@vinschen.de>
1722
1723 * autoload.cc (IsProcessorFeaturePresent): Add.
1724 * fhandler_proc.cc (format_proc_cpuinfo): Add case for 9x systems.
1725
c58555c7
CV
17262003-03-13 Corinna Vinschen <corinna@vinschen.de>
1727
1728 * fhandler_proc.cc (format_proc_cpuinfo): Fix vendor id in cpuid case.
1729
49a0d53c
CV
17302003-03-13 Corinna Vinschen <corinna@vinschen.de>
1731
1732 * net.cc (cygwin_rcmd): Use correct file descriptor in call to fdsock.
1733 (cygwin_rexec): Ditto.
1734
6fcd5661
CF
17352003-03-13 Christopher Faylor <cgf@redhat.com>
1736
1737 * fhandler_tty.cc (fhandler_tty_slave::close): Fix typo in debug
1738 output.
1739
1740 * syscalls.cc (rename): Assume that DELETE_ON_CLOSE works on Win9x.
1741
aa39b7f7
CV
17422003-03-11 Corinna Vinschen <corinna@vinschen.de>
1743
1744 * fhandler_socket.cc (fhandler_socket::dup): Don't call
1745 fhandler_base::dup() but call DuplicateHandle directly instead to have
1746 control over socket inheritence.
1747
2afa7f58
CV
17482003-03-11 Corinna Vinschen <corinna@vinschen.de>
1749
1750 * fhandler_socket.cc (fhandler_socket::dup): On NT systems avoid
1751 using WinSock2 socket duplication methods. Add comment.
1752
17532003-03-11 Pierre Humblet <pierre.humblet@ieee.org>
1754
1755 * fhandler_socket.cc (fhandler_socket::fixup_after_fork):
1756 Set io_handle to INVALID_SOCKET in case of failure.
1757 (fhandler_socket::dup): Return 0 if the io_handle is valid.
1758
556ceaeb
CV
17592003-03-10 Corinna Vinschen <corinna@vinschen.de>
1760
1761 * sec_acl.cc (setacl): Don't handle DELETE flag specially.
1762 * security.cc (alloc_sd): Ditto.
1763
a201401c
CV
17642003-03-09 Corinna Vinschen <corinna@vinschen.de>
1765
6bbf711e 1766 * winver.rc: Change Copyright hint to include 2003.
a201401c 1767
b1aae492
CV
17682003-03-09 Corinna Vinschen <corinna@vinschen.de>
1769
1770 Switch to 32/64 datatypes:
1771 * Makefile.in (OBSOLETE_FUNCTIONS): Add open acl aclcheck aclfrommode
1772 aclfrompbits aclfromtext aclsort acltomode acltopbits acltotext chown
1773 facl fchown fgetpos fopen freopen fseeko fsetpos fstat ftello
1774 ftruncate getegid geteuid getgid getgrent getgrgid getgrnam getgroups
1775 getpwuid getpwuid_r getuid initgroups lchown lseek lstat mknod mmap
1776 seekdir setegid seteuid setgid setgroups setregid setreuid setuid stat
1777 telldir truncate.
1778 (NEW_FUNCTIONS): Add _open64 acl32 aclcheck32 aclfrommode32
1779 aclfrompbits32 aclfromtext32 aclsort32 acltomode32 acltopbits32
1780 acltotext32 chown32 facl32 fchown32 fgetpos64 fopen64 freopen64
1781 fseeko64 fsetpos64 fstat64 ftello64 ftruncate64 getegid32 geteuid32
1782 getgid32 getgrent32 getgrgid32 getgrnam32 getgroups32 getpwuid32
1783 getpwuid_r32 getuid32 initgroups32 lchown32 lseek64 lstat64 mknod32
1784 mmap64 seekdir64 setegid32 seteuid32 setgid32 setgroups32 setregid32
1785 setreuid32 setuid32 stat64 telldir64 truncate64 to substitute the
1786 above.
1787 * cygserver_shm.h (class client_request_shm): Change uid_t and gid_t
1788 members to __uid32_t and __gid32_t.
1789 * cygwin.din: Add symbols acl32 aclcheck32 aclfrommode32
1790 aclfrompbits32 aclfromtext32 aclsort32 acltomode32 acltopbits32
1791 acltotext32 facl32 fgetpos64 fopen64 freopen64 fseeko64 fsetpos64
1792 _fstat64 ftello64 _lseek64 mknod32 _open64.
1793 * glob.c: Include perprocess.h.
1794 (globtilde): Call getpwuid32 and getuid32 instead of getpwuid and
1795 getuid.
1796 (g_lstat): Check for applications API version to call the appropriate
1797 typed gl_lstat function.
1798 (g_stat): Ditto for gl_stat.
1799 * shm.cc (client_request_shm::client_request_shm): Call geteuid32
1800 and getegid32 instead of geteuid and getegid throughout.
1801 * syscalls.cc (_open64): New alias for open.
1802 (_lseek64): New alias for lseek64.
1803 (_fstat64): New alias for fseek64.
1804 (mknod32): New function.
1805 (mknod): Calls mknod32 now.
1806 * winsup.h: Make function declarations for getuid32, geteuid32,
1807 and getpwuid32 accessible for plain C sources. Add declarations
1808 for getegid32 and getpwnam.
1809 * include/cygwin/version.h: Bum API minor number to 78.
1810 * include/sys/cygwin.h: Guard C++ specific members of struct
1811 per_process against inclusion in plain C sources.
1812 * include/sys/mman.h (mman): Add guard to avoid type clash when
1813 compiling Cygwin.
1814
659fb3ff
CF
18152003-03-09 Christopher Faylor <cgf@redhat.com>
1816
d580d86c 1817 * include/cygwin/version.h: Bump DLL minor number to 22.
659fb3ff 1818
c367dfd0
CF
18192003-03-09 Christopher Faylor <cgf@redhat.com>
1820
1821 Do some minor reformatting of 'extern "C"' use throughout.
1822
18232003-03-06 Christopher January <chris@atomice.net>
1824
1825 * autoload.cc (GetSystemTimes): Define new autoload function.
1826 * fhandler_proc.cc (proc_listing): Add cpuinfo and partitions entries.
1827 (fhandler_proc::fill_filebuf): Add PROC_CPUINFO and PROC_PARTITIONS
1828 cases.
1829 (format_proc_uptime): Use GetSystemTimes if available.
1830 (read_value): New macro.
1831 (print): New macro.
1832 (cpuid): New function.
1833 (can_set_flag): New function.
1834 (format_proc_cpuinfo): New function.
1835 (format_proc_partitions): New function.
1836
36c4a441
CF
18372003-03-09 Christopher Faylor <cgf@redhat.com>
1838
1839 * syscalls.cc (unlink): Attempt to be more clever about setting
1840 attributes of file. Only open file in query mode to avoid having to
1841 mess with security stuff for reading.
1842
639ebe29
CV
18432003-03-09 Corinna Vinschen <corinna@vinschen.de>
1844
1845 * rmsym: Fix regular expression.
1846
3a1d827f
CF
18472003-03-09 Christopher Faylor <cgf@redhat.com>
1848
1849 * Makefile.in: Change from using new-* to cygwin0 for temporary
1850 targets.
1851
ca0e9071
CV
18522003-03-09 Corinna Vinschen <corinna@vinschen.de>
1853
1854 * include/cygwin/socket.h: Set SOMAXCONN to Winsock2 value.
1855
ed269cea
CF
18562003-03-08 Christopher Faylor <cgf@redhat.com>
1857
1858 * syscalls.cc (unlink): Always attempt to use FILE_FLAG_CLOSE_ON_DELETE
1859 to delete files since this allows us to preserve the protection of hard
1860 linked files.
1861 (link): Generate full path for potentially recalculated .lnk target.
1862
1114c3d0
CF
18632003-03-08 Christopher Faylor <cgf@redhat.com>
1864
1865 Revert below changes regarding _pinfo::cmdline.
1866
d66ac2bc
CV
18672003-03-08 Corinna Vinschen <corinna@vinschen.de>
1868
1869 * external.cc (cygwin_internal): Change n to __off64_t to match change
1870 of _pinfo::cmdline.
1871 * fhandler.h (class fhandler_virtual): Change filesize member to
1872 __off64_t.
1873 * fhandler_proc.cc (format_proc_meminfo): Change to return __off64_t.
1874 (format_proc_stat): Ditto.
1875 (format_proc_uptime): Ditto.
1876 * fhandler_process.cc (format_process_stat): Ditto.
1877 (format_process_status): Ditto.
1878 (format_process_statm): Ditto.
1879 * pinfo.cc (_pinfo::cmdline): Expect __off64_t parameter.
1880 * pinfo.h (class _pinfo): Change declaration of cmdline accordingly.
1881
762520f3
CF
18822003-03-07 Christopher Faylor <cgf@redhat.com>
1883
1884 * path.h (PATH_LNK): New enum val.
1885 (path_conv::is_lnk_symlink): New function. True if path represents
1886 .lnk style symlink.
1887 * path.cc (check_shortcut): Set PATH_LNK in pflags when appropriate.
1888 (symlink_info::check): Ditto. Remove PATH_LNK from pflags initially.
1889 * syscalls.cc (unlink): Always remove readonly attribute from a symlink
1890 regardless of type.
1891 (link): (from Corinna Vinschen) Allow links to symlinks. Reset
1892 attributes on a symlink after successful link creation.
1893 (chmod): Use is_lnk_symlink where appropriate.
1894 (rename): Ditto.
1895
18962003-03-07 Pierre Humblet <pierre.humblet@ieee.org>
1897
1898 * tty.cc (create_tty_master): Call GetComputerName instead of
1899 cygwin_gethostname. Set ut_id.
1900 * syscalls.cc (login): Call endutent.
1901 (setutent): Do not seek after a fresh open.
1902
6f8102cb
CV
19032003-03-07 Corinna Vinschen <corinna@vinschen.de>
1904
1905 * syscalls.cc (seteuid32): Fix formatting.
1906
88243328
TP
19072003-03-04 Thomas Pfaff <tpfaff@gmx.net>
1908
1909 * thread.cc (MTinterface::fixup_after_fork): Initialize mainthread
1910 prior to pthread objects.
762520f3 1911
12390bc4
CV
19122003-03-04 Jason Tishler <jason@tishler.net>
1913
1914 * fhandler_socket.cc (fhandler_socket::dup): Initialize type.
1915
c418817e
CF
19162003-03-03 Christopher Faylor <cgf@redhat.com>
1917
1918 * fhandler.h (fhandler_tty_slave::close): Declare new function.
1919 (fhandler_tty_slave::dup): Declare new function.
1920 (fhandler_tty_slave::fixup_after_function): Declare new function.
1921 * fhandler_tty.cc (fhandler_tty_slave_open): Only increment
1922 fhandler_console::open_fhs when associated with a pty.
1923 (fhandler_tty_slave::close): Define new function. Decrement
1924 fhandler_console::open_fhs when associated with a pty.
1925 (fhandler_tty_slave::dup): Define new function. Increment
1926 fhandler_console::open_fhs when associated with a pty.
1927 (fhandler_tty_slave::fixup_after_fork): Define new function. Increment
1928 fhandler_console::open_fhs when associated with a pty.
1929
e11fe31b
CF
19302003-03-03 Christopher Faylor <cgf@redhat.com>
1931
1932 * fhandler_tty.cc (fhandler_pty_slave::open): Grudgingly increment
1933 fhandler_console::open_fhs here.
1934 (fhandler_pty_slave::close): Ditto for close.
1935
cffdb4b1
CF
19362003-03-02 Christopher Faylor <cgf@redhat.com>
1937
1938 * lib/getopt.c: Refresh from NetBSD sources.
1939
d5d2ffee
CF
19402003-03-02 Christopher Faylor <cgf@redhat.com>
1941
1942 * fhandler_console.cc (fhandler_console::close): Don't decrement
1943 in use counter if in vfork fixup stage.
1944
c2c6b170
CF
19452003-03-02 Christopher Faylor <cgf@redhat.com>
1946
1947 * lib/getopt.c: Nuke use of unneeded BSDisms.
1948
8b19b43d
CF
19492003-03-02 Christopher Faylor <cgf@redhat.com>
1950
1951 * dll_init.cc (dll_list::load_after_fork): Don't revert to LoadLibrary
1952 if LoadLibraryEx fails.
1953 * dtable.cc (dtable::dec_console_fds): Eliminate.
1954 (dtable::release): Don't treat console specially.
1955 (dtable::build_fhandler): Ditto.
1956 * dtable.h (console_fds): Eliminate.
1957 (dtable::dec_console_fds): Eliminate.
1958 (dtable::inc_console_fds): Eliminate.
1959 * fhandler.h (fhandler_console::open_fhs): New static element.
1960 * fhandler_console.cc (fhandler_console::open): Increment open_fs.
1961 (fhandler_console::close): Call FreeConsole if no more open consoles
1962 and ctty is not associated with the console.
1963 * syscalls.cc (setsid): Simplify check for when to call FreeConsole.
1964 (check_pty_fds): Eliminate definition.
1965 * winsup.h (check_pty_fds): Eliminate declaration.
1966
3efc65f7
CF
19672003-03-02 Christopher Faylor <cgf@redhat.com>
1968
1969 * dll_init.cc (dll_list::load_after_fork): Fix typo where result of
1970 LoadLibrary was ignored.
1971
5a082e9e
CV
19722003-03-01 Corinna Vinschen <corinna@vinschen.de>
1973
1974 * fhandler_socket.cc (fhandler_socket::bind): Open and write socket
1975 file using Win32 calls.
1976
9d913f07
CV
19772003-03-01 Corinna Vinschen <corinna@vinschen.de>
1978
1979 * fhandler_socket.cc (get_inet_addr): Open and read socket file using
1980 Win32 calls.
1981
005c3065
CF
19822003-02-28 Christopher Faylor <cgf@redhat.com>
1983
1984 * cygwin.din: Wrap atexit and exit with cygwin, thread-safe functions.
1985 * dcrt0.cc (cygwin_atexit): New function.
1986 (cygwin_exit): Ditto.
1987
27b4082a
PH
19882003-02-28 Pierre Humblet <pierre.humblet@ieee.org>
1989
1990 * syscalls.cc (fstat64): Pass get_name () to pc.
005c3065 1991 (access): Pass fn to stat_worker.
27b4082a
PH
1992
19932003-03-27 Corinna Vinschen <corinna@vinschen.de>
5777b970
CV
1994
1995 * fhandler_socket.cc (class sock_event): New class managing Winsock
1996 events for interruptible socket calls.
1997 (fhandler_socket::connect): Move support for interruptible call to
1998 class sock_event. Use class object instead.
1999 (fhandler_socket::accept): Ditto. Remove useless casts.
2000
005c3065 20012003-03-27 Thomas Pfaff <tpfaff@gmx.net>
5777b970
CV
2002
2003 * fhandler_socket.cc (fhandler_socket::connect): Add support for
2004 an interruptable connect.
2005
7b2ce663
CV
20062003-02-27 Pierre Humblet <pierre.humblet@ieee.org>
2007
2008 * uinfo.cc (internal_getlogin): Only update user.groups.pgsid
2009 if the call to set the primary group succeeds.
2010
0e7a60fe
CF
20112003-02-27 Christopher Faylor <cgf@redhat.com>
2012
2013 * cygthread::detach: Improve error message.
2014
61a52599
CV
20152003-02-26 Pierre Humblet <pierre.humblet@ieee.org>
2016
2017 * sec_helper.cc (get_sids_info): debug_print owner_sid and group_sid.
2018
6b9a9ce6
CV
20192003-02-25 Corinna Vinschen <corinna@vinschen.de>
2020
2021 * mmap.cc (mmap64): Fix returned address by taking the granularity
2022 into account.
2023
1ffc44aa
PH
20242003-02-23 Pierre Humblet <pierre.humblet@ieee.org>
2025
2026 * syslog.cc (syslog): Do not unlock the file before closing it
2027 and remove debug_printf about stream errors.
2028
a066f364
CF
20292003-02-22 Christopher Faylor <cgf@redhat.com>
2030
2031 * cygmalloc.h: Remove MORECORE_CANNOT_TRIM. It's not true.
2032 # cygwin.din: Export mallinfo.
2033 # malloc_wrapper.cc (mallinfo): New function.
2034
878e60c5
CF
20352003-02-22 Pierre Humblet <pierre.humblet@ieee.org>
2036
2037 * syslog.cc (syslog): Do not print the Windows pid. Print the Cygwin
2038 pid as an unsigned decimal. On Win95 print a timestamp and attempt to
2039 lock the file up to four times in 3 ms.
2040
b1d1e50d
CV
20412003-02-21 Corinna Vinschen <corinna@vinschen.de>
2042
2043 * fhandler_socket.cc (fhandler_socket::fhandler_socket): Fix compiler
2044 warning.
2045 (fhandler_socket::fstat): Simplify. Set st_uid/st_gid to effective
2046 uid/gid of current process in case of open sockets.
2047
cf762b08
CV
20482003-02-21 Corinna Vinschen <corinna@vinschen.de>
2049
2050 * dtable.cc (dtable::build_fhandler_from_name): Set some fhandler
2051 data on sockets to evaluate AF_LOCAL sockets correctly.
2052 (dtable::build_fhandler): Set unit number on sockets.
2053 * fhandler.h (fhandler_socket): Add unit number.
2054 (fhandler_socket::get_unit): New method.
2055 * fhandler_socket.cc (fhandler_socket::fhandler_socket): Set unit
2056 number.
2057 (fhandler_socket::fstat): Reorganize to return more Linux-like
2058 values.
2059 * net.cc: include ctype.h.
2060 (fdsock): Set unit number when building fhandler.
2061 * path.cc (path_conv::check): Set device type to FH_SOCKET if file
2062 is a AF_UNIX socket.
2063 (get_devn): Evaluate unit for virtual socket devices.
2064 (win32_device_name): Set windows path for sockets to unix_path with
2065 just backslashes to keep the different names.
2066 * syscalls.cc (fstat64): Don't override st_ino, st_dev and st_rdev
2067 for sockets.
2068 (stat_worker): Ditto.
2069
20702003-02-21 Pierre Humblet <pierre.humblet@ieee.org>
2071
2072 * autoload.cc (AccessCheck): Add.
2073 (DuplicateToken): Add.
2074 * security.h (check_file_access): Declare.
2075 * syscalls.cc (access): Convert path to Windows, check existence
2076 and readonly attribute. Call check_file_access instead of acl_access.
2077 * security.cc (check_file_access): Create.
2078 * sec_acl (acl_access): Delete.
2079
5cd82412
CF
20802003-02-19 Christopher Faylor <cgf@redhat.com>
2081
2082 * fhandler.cc (fhandler_base::open): Move some filesystem specific
2083 stuff.
2084 (fhandler_disk_file::open): Accept some filesystem specific stuff.
2085 * sigproc.cc (wait_for_sigthread): Become slightly more thread safe.
2086 (sig_send): Don't assume that signal thread is ready.
2087
892d8962
CV
20882003-02-20 Corinna Vinschen <corinna@vinschen.de>
2089
2090 * wincap.h (wincap): Remove unnecessary definition of
2091 supports_sparse_files.
2092 * wincap.cc: Ditto.
2093
518f5d49
CV
20942003-02-20 Corinna Vinschen <corinna@vinschen.de>
2095
2096 * fhandler_disk_file.cc (fhandler_disk_file::opendir): Check descriptor
2097 created by cygheap_fdnew constructor.
2098 * fhandler_virtual.cc (fhandler_virtual::opendir): Ditto.
2099 * fhandler_socket.cc (fhandler_socket::accept): Ditto and move
2100 creation of file descriptor behind blocking OS call.
2101 * net.cc (cygwin_socket): Ditto.
2102 (cygwin_rcmd): Ditto.
2103 (cygwin_rresvport): Ditto.
2104 (cygwin_rexec): Ditto.
2105 (socketpair): Ditto.
2106
3a88cf1b
CV
21072003-02-20 Corinna Vinschen <corinna@vinschen.de>
2108
2109 * autoload.cc (GetCompressedFileSize): Add.
2110 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Compute
2111 st_blocks value from GetCompressedFileSize() if available.
2112
79207923
CV
21132003-02-18 Vaclav Haisman <V.Haisman@sh.cvut.cz>
2114
2115 * wincap.h (wincaps::supports_sparse_files): New flag.
2116 (wincapc::supports_sparse_files): New method.
2117 * wincap.cc (wincap_unknown): Define value for the new flag.
2118 (wincap_95): Ditto.
2119 (wincap_95osr2): Ditto.
2120 (wincap_98): Ditto.
2121 (wincap_98se): Ditto.
2122 (wincap_me): Ditto.
2123 (wincap_nt3): Ditto.
2124 (wincap_nt4): Ditto.
2125 (wincap_nt4sp4): Ditto.
2126 (wincap_2000): Ditto.
2127 (wincap_xp): Ditto.
2128 * path.h (path_conv::fs_flags): New method.
005c3065
CF
2129 * fhandler_disk_file.cc: Include winioctl.h for DeviceIoControl.
2130 (fhandler_disk_file::open): Set newly created and truncated files as
79207923
CV
2131 sparse on platforms that support it.
2132
afe13e84
CV
21332003-02-17 Pierre Humblet <pierre.humblet@ieee.org>
2134
2135 * grp.cc (internal_getgroups): Handle properly tokens with
2136 no groups. Fix bug introduced on 2003-02-04.
2137
8fc16812
CF
21382003-02-16 Christopher Faylor <cgf@redhat.com>
2139
408e9b2f 2140 * cygwin.din: Export all appropriate newlib libm functions. Sort.
8fc16812
CF
2141 * include/cygwin/version.h: Bump API minor number.
2142
f655eadf
CF
21432003-02-15 Christopher Faylor <cgf@redhat.com>
2144
8fc16812 2145 * cygwin.din: Export all appropriate newlib libc functions.
f655eadf
CF
2146 * include/cygwin/version.h: Bump API minor number.
2147
4d9ba012
CV
21482003-02-14 Jason Tishler <jason@tishler.net>
2149
2150 * mmap.cc (mprotect): Add missing break.
2151
dff01e3a
CF
21522003-02-13 Christopher Faylor <cgf@redhat.com>
2153
2154 * exceptions.cc (try_to_debug): Don't reset priority when returning
2155 from non-waitloop call.
d1d1797e
CF
2156
21572003-02-13 Vaclav Haisman <V.Haisman@sh.cvut.cz>
005c3065 2158 Christopher Faylor <cgf@redhat.com>
d1d1797e
CF
2159
2160 * fhandler_console.cc (fhandler_console::write_normal): Use MessageBeep
2161 for bell sound.
2162 * autoload.cc (MessageBeep): Add.
2163
97c61aeb
CF
21642003-02-13 Christopher Faylor <cgf@redhat.com>
2165
2166 * include/cygwin/types.h: Use correct ifdef guard for u_ definitions.
2167
a200c081
CF
21682003-02-13 Christopher Faylor <cgf@redhat.com>
2169
2170 * environ.cc (environ_init): Use strechr.
2171
2858de3a
CF
21722003-02-13 Christopher Faylor <cgf@redhat.com>
2173
2174 * include/cygwin/in.h (sockaddr_in): Fix typo.
2175
75c8a70c
CF
21762003-02-12 Christopher Faylor <cgf@redhat.com>
2177
2178 * path.h (path_conv): Reorganize slightly.
2179
939d19b0
CF
21802003-02-12 Christopher Faylor <cgf@redhat.com>
2181
2182 * fhandler_tty.cc (process_input): Add sanity check to ensure that
2183 console typeahead is cleared on signal.
2184
7a44ba05
CF
21852003-02-12 Christopher Faylor <cgf@redhat.com>
2186
2187 * spawn.cc (linebuf::~linebuf): Resurrect commented out (for
2188 debugging?) code.
2189
407b8df6
CF
21902003-02-10 Ralf Habacker <ralf.habacker@freenet.de>
2191
2192 * include/cygwin/in.h (in_attr_t): Define new type.
2193 * include/arpa/inet.h (inet_addr): Change return type to in_addr_t.
2194 (inet_lnaof): Ditto.
2195 (inet_netof): Ditto.
2196 (inet_network): Ditto.
2197
21982003-02-10 Christopher Faylor <cgf@redhat.com>
2199
2200 * include/cygwin/types.h: Move many *_t typedefs here. Protect them
2201 with ifdefs.
2202 * fhandler_disk_file.cc (fhandler_disk_file::fstat): Change ntsec_atts to mode_t.
2203 * security.cc (get_attribute_from_acl): Accept mode_t attribute.
2204 (get_nt_attribute): Ditto.
2205 (get_file_attribute): Ditto.
2206 (get_nt_object_attribute): Ditto.
2207 (get_object_attribute): Ditto.
2208 * security.h: Reflect above changes.
2209 * syscalls.cc (chown_worker): Change attrib to mode_t.
2210
ad80bc42
CF
22112003-02-08 Christopher Faylor <cgf@redhat.com>
2212
67c64e3b 2213 * include/cygwin/version.h: Bump DLL minor number to 21.
ad80bc42
CF
2214
22152003-02-07 Christopher Faylor <cgf@redhat.com>
2216
2217 * malloc.cc (DEFAULT_MMAP_THRESHOLD): Bump down to 16MB thanks to below
2218 changes.
2219
4136fdb1
CV
22202003-02-07 Corinna Vinschen <corinna@vinschen.de>
2221
2222 * mmap.cc (mmap_record::alloc_map): De-inline. Add offset and length
2223 parameter. Only protect pages actually unused currently. Do job
2224 of map_map() when initializing a map.
2225 (mmap_record::map_map): Reduce functionality for the reuse case
2226 of private anonymous mapping.
2227 (mmap_record::fixup_map): Format change.
2228 (list::add_record): Add offset and length parameter to call
2229 mmap_record::alloc_map() correctly.
293ce810 2230 (mmap64): Rename `l' variable to `map_list'. Accommodate above changes.
4136fdb1
CV
2231 (munmap): Rename `l' variable to `map_list'.
2232 (msync): Ditto.
2233 (fhandler_disk_file::mmap): Streamline code.
2234 (mprotect): Ditto.
2235 (fixup_mmaps_after_fork): Rename `l' variable to `map_list'.
2236
49b84ce4
CF
22372003-02-07 Vaclav Haisman <V.Haisman@sh.cvut.cz>
2238 Christopher Faylor <cgf@redhat.com>
2239
2240 * exceptions.cc (try_to_debug): Set priority of current thread rather
2241 than the main thread. Make busy waiting loop less busy. Restore
2242 priority when function returns.
2243
bc5b63ed
CF
22442003-02-07 Christopher Faylor <cgf@redhat.com>
2245
2246 * malloc.cc (DEFAULT_MMAP_THRESHOLD): Set high to avoid mmaps.
2247
22482003-02-07 Christopher Faylor <cgf@redhat.com>
2249
2250 * pipe.cc (fhandler_pipe::close): Avoid extraneous this->.
2251
1de8d164
CF
22522003-02-06 Christopher Faylor <cgf@redhat.com>
2253
2254 * heap.cc (heap_init): Remove debugging code.
2255
565e8015
CV
22562003-02-06 Pierre Humblet <pierre.humblet@ieee.org>
2257
2258 * security.h: Introduce names UNKNOWN_UID and UNKNOWN_GID and delete
1de8d164 2259 declaration of is_grp_member.
565e8015
CV
2260 * uinfo.cc (internal_getlogin): Use UNKNOWN_GID.
2261 * passwd.cc (pwdgrp::read_passwd): Use UNKNOWN_UID.
2262 * grp.cc (pwdgrp::read_group): Change group name to provide better
2263 feedback.
2264 (getgrgid): Use gid16togid32.
2265 * sec_helper.cc (is_grp_member): Delete.
2266
d238c1b4
CF
22672003-02-05 Christopher Faylor <cgf@redhat.com>
2268
2269 * path.cc: Change 'to_posix_p' to 'to_posix' throughout.
2270 (conv_path_list_buf_size): Accommodate relative paths.
2271
b7f52fe8
CF
22722003-02-05 Christopher Faylor <cgf@redhat.com>
2273
2274 * path.cc (etc::dir_changed): Fix debug printf.
2275
62cd433e
CV
22762003-02-05 Corinna Vinschen <corinna@vinschen.de>
2277
2278 * sec_acl.cc (setacl): Move all permission settings to beginning of
2279 loop. Set default rights to same values as in alloc_sd(). Set DELETE
2280 for owner and default owner only if S_IWOTH is given.
2281
22822003-02-05 Pierre Humblet <pierre.humblet@ieee.org>
2283
2284 * sec_acl.cc: Change all __aclent16_t to __aclent32_t except in
2285 wrapper function definitions. Replace call to the aclXYZ functions by
2286 calls aclXYZ32.
2287 (searchace): Change type of third argument to __uid32_t and use
2288 ILLEGAL_UID instead of -1;
2289 (setacl): Remove some initializations. Only give STANDARD_RIGHTS_WRITE
2290 for S_IWOTH. Replace -1 by ILLEGAL_UID.
2291 (getacl): Change type of owner_sid, group_sid and ace_sid to cygpsid.
2292 In last else clause, suppress second call to ace_sid.get_id and use
2293 TRUE in first call. Replace EqualSid by ==.
2294 (acl_access): Call internal_getgroups in USER and GROUP cases.
2295 (acecmp: Define static.
2296 (acl32): Create from 16 bit type.
2297 (facl32): Ditto.
2298 (lacl32): Ditto.
2299 (aclcheck32): Ditto.
2300 (aclsort32): Ditto.
2301 (acltomode32): Ditto.
2302 (aclfrommode32): Ditto.
2303 (acltopbits32): Ditto.
2304 (aclfrompbits32): Ditto.
2305 (acltotext32): Ditto.
2306 (aclfromtext32): Ditto, and use strechr.
2307 (acl16to32): Create.
2308 (acl): Make it a wrapper function.
2309 (facl): Ditto.
2310 (lacl): Ditto.
2311 (aclcheck): Ditto.
2312 (aclsort): Ditto.
2313 (acltomode): Ditto.
2314 (aclfrommode): Ditto.
2315 (acltopbits): Ditto.
2316 (aclfrompbits): Ditto.
2317 (acltotext): Ditto.
2318 (aclfromtext): Ditto.
2319 * security.cc (write_sd): Call set_process_privilege and check
2320 ownership.
2321 (alloc_sd): Remove call to set_process_privilege and the owner check.
2322
cadd065b
CF
23232003-02-05 Christopher Faylor <cgf@redhat.com>
2324
2325 * include/sys/cygwin.h: Use C-style comments.
2326
0c8455c3
CV
23272003-02-05 Pierre Humblet <pierre.humblet@ieee.org>
2328
2329 * sec_helper.cc (get_sids_info): New function.
2330 * security.cc (extract_nt_dom_user): Simplify with strechr.
2331 (get_user_groups): Initialize glen to MAX_SID_LEN.
2332 (get_user_local_groups): Ditto.
2333 (get_attribute_from_acl): Define ace_sid as cygpsid.
2334 (get_nt_attribute): Define owner_sid and group_sid as cygpsid.
2335 Call get_sids_info instead of cygsid.get_{u,g}id and is_grp_member.
2336 (get_nt_object_attribute): Ditto.
2337 (alloc_sd): Define ace_sid as cygpsid.
2338
5ae9331a
TP
23392003-02-04 Thomas Pfaff <tpfaff@gmx.net>
2340
2341 * syscalls.cc (struct system_cleanup_args): New struct.
2342 (system_cleanup): New function.
2343 (system): Use pthread_cleanup_push and _pop to save and restore
2344 signal handlers and sigprocmask.
2345
3dbafd87
CV
23462003-02-04 Corinna Vinschen <corinna@vinschen.de>
2347
2348 * path.cc (symlink): Create security attributes so that only the
2349 user can modify the symlink.
2350 * security.cc (set_security_attribute): Remove symlink special
2351 handling.
2352
0daf2561
CV
23532003-02-04 Pierre Humblet <pierre.humblet@ieee.org>
2354
2355 * grp.cc (internal_getgroups): Do not return without closing
2356 the process handle.
2357
4a21c2d5
CV
23582003-02-04 Pierre Humblet <pierre.humblet@ieee.org>
2359
2360 * security.h (class cygpsid): New class.
2361 (class cygsid): Use cygpsid as base. Remove members psid, get_id,
2362 get_uid, get_gid, string, debug_printf and the == and != operators.
2363 (cygsidlist::clear_supp): Only do work if setgroups has been called.
2364 * sec_helper.cc: Define sid_auth NO_COPY.
2365 (cygpsid::operator==): New operator.
2366 (cygpsid::get_id): New function.
2367 (cygpsid::string): New function.
2368 (cygsid::string): Delete.
2369 (cygsid::get_id): Delete.
2370 * pwdgrp.h: Change arguments of internal_getpwsid,
2371 internal_getgrsid and internal_getgroups to cygpsid.
2372 * passwd.cc (internal_getpwsid): Change argument from cygsid to cygpsid.
d238c1b4 2373 * grp.cc (internal_getgrsid): Ditto.
4a21c2d5
CV
2374 (internal_getgroups): Ditto.
2375
335556d5
CF
23762003-02-03 Christopher Faylor <cgf@redhat.com>
2377
2378 Eliminate most unneeded this-> pointers throughout.
2379
153e83c6
CV
23802003-02-03 Pierre Humblet <pierre.humblet@ieee.org>
2381
2382 * security.h: Add third argument to set_process_privilege.
2383 * autoload.cc: Add OpenThreadToken.
2384 * sec_helper.cc (set_process_privilege): Add and use use_thread
2385 argument.
2386 * security.cc (alloc_sd): Modify call to set_process_privilege.
2387 Remember the result in each process. If failed and file owner is not
2388 the user, fail.
2389
f0f3ea68
CV
23902003-02-03 Corinna Vinschen <corinna@vinschen.de>
2391
2392 * fhandler_socket.cc (fhandler_socket::recvfrom): Return buffer
2393 length and don't set errno in case of WSAEMSGSIZE error.
2394 (fhandler_socket::recvmsg): Ditto.
2395
6688a061
CF
23962003-02-01 Christopher Faylor <cgf@redhat.com>
2397
2398 * grp.cc (getgrent32): Only refresh group entries when at beginning.
2399 (internal_getgrsid): Only refresh if uninitialized.
2400 (internal_getgrent): Ditto.
2401 * passwd.cc (getpwent): Only refresh passwd entries when at beginning.
2402 (pwdgrp::read_passwd): linebuf *cannot* be NO_COPY.
2403 (internal_getpwsid): Only refresh if uninitialized.
2404 (getpass): No need to refresh passwd data here.
2405 * pwdgrp.h (refresh): Eliminate default.
2406
a5a93a62
CF
24072003-01-31 Christopher Faylor <cgf@redhat.com>
2408
2409 * dlfcn.cc (dlerror): Only report load errors once per error.
2410
b0a82a85
CF
24112003-01-31 Christopher Faylor <cgf@redhat.com>
2412
2413 * fhandler_serial.cc (fhandler_serial::open): Avoid extraneous setting
2414 of res.
2415
2416 * termios.cc (tcsetattr): Correctly record errno after tcsetattr call.
2417
24182003-01-31 Troy Curtiss <troyc@usa.net>
2419
2420 * fhandler_serial.cc (fhandler_serial::tcsetattr): Add error-checking
2421 so that if any Win32 SetComm*() calls fail, errno gets set to EINVAL
2422 and tcsetattr() returns -1. Catch invalid bitrates, mostly. If baud
2423 rate setting is B0, just drop DTR and leave Win32 DCB bitrate as-is
2424 since 0 is not a valid Win32 setting.
2425 (fhandler_serial::tcgetattr): If DTR is low, populate the bitrate as
2426 B0, otherwise get it from the DCB.
2427
949c3da1
CF
24282003-01-31 Christopher Faylor <cgf@redhat.com>
2429
2430 * passwd.cc (pwdgrp::read_passwd): linebuf *must* be static (from
2431 Pierre Humblet).
2432 * pwdgrp.h (pwdgrp::refresh): Avoid calling read function if we already
2433 have lock since that means we are in the process of reading the file.
2434
485d85bf
CF
24352003-01-31 Jason Tishler <jason@tishler.net>
2436
2437 * shared.cc (shared_info::heap_chunk_size): Use correct variable when
2438 reading HKLM.
2439
704ce461
CF
24402003-01-30 Christopher Faylor <cgf@redhat.com>
2441
2442 * fhandler_registry.cc (fhandler_registry::exists): Fix off-by-one
2443 error when inspecting path.
2444
ba6e1083
CF
24452003-01-29 Christopher Faylor <cgf@redhat.com>
2446
2447 * lib/getopt.c: Allow environment variable control of POSIXLY_INCORRECT
2448 behavior.
2449
24502003-01-28 Corinna Vinschen <corinna@vinschen.de>
01e3c897
CV
2451
2452 * fhandler_socket.cc (fhandler_socket::accept): On successful execution
2453 set connection state of returned socket to CONNECTED.
2454
dfb366da
CF
24552003-01-27 Christopher Faylor <cgf@redhat.com>
2456
2457 * passwd.cc (pwdgrp::parse_passwd): Be more unforgiving about
2458 non-numeric fields.
2459
03dba1de
CF
24602003-01-26 Christopher Faylor <cgf@redhat.com>
2461
2462 * uinfo.cc (pwdgrp::next_num): Remove check for NULL since it is no
2463 longer a valid return from next_str.
2464 (pwdgrp::add_line): Duh. Revert to use strchr.
2465
fea48988
CF
24662003-01-26 Christopher Faylor <cgf@redhat.com>
2467
ca6018a0 2468 * string.h (strechr): New function.
fea48988
CF
2469 * uinfo.cc (pwdgrp::next_str): Search only for input char in string.
2470 Return EOS on failure. Don't check for NULL since it shouldn't be
2471 possible.
2472 (pwdgrp::add_line): Revert to replacing '\n' in input line with '\0'.
2473 (pwdgrp::next_num): Pass explicit separator character to next_str.
2474 * grp.cc (pwdgrp::parse_group): Ditto.
2475 * passwd.cc (pwdgrp::parse_passwd): Ditto. Revamp test for garbage
2476 input.
2477 * pwdgrp.h (pwdgrp::next_str): Don't use default parameter.
2478
9a751621
CF
24792003-01-26 Christopher Faylor <cgf@redhat.com>
2480
2481 * uinfo.cc (pwdgrp::load): Regularize strace output. Add warning for
2482 CreateFile failure.
2483
c9133395
CF
24842003-01-26 Christopher Faylor <cgf@redhat.com>
2485
bdbd7fb6
CF
2486 * passwd.cc (pwdgrp::parse_passwd): Eliminate use of memset. The
2487 structure should always be completely filled out.
2488 * grp.cc (pwdgrp::parse_group): Ditto.
2489
24902003-01-26 Christopher Faylor <cgf@redhat.com>
2491
2492 * grp.cc (pwdgrp::parse_group): Fix off-by-one problem in allocating
c9133395 2493 gr_mem.
65037056
CF
2494
24952003-01-26 Christopher Faylor <cgf@redhat.com>
2496
2497 * include/sys/strace.h (paranoid_printf): Define as not being part of
2498 "all" output.
2499
25002003-01-25 Christopher Faylor <cgf@redhat.com>
2501
2502 * pwdgrp.h (pwdgrp::next_num): Rename from next_int. Returns
2503 true/false if parse operation succeeded.
2504 (pwdgrp::reparse): Remove.
2505 (pwdgrp::raw_ptr): New function. Returns pointer in line.
2506 (pwdgrp::next_num): New functions for parsing other than unsigned long.
2507 * grp.cc (pwdgrp::parse_group): Reinstate previous parsing behavior.
2508 Don't fill in fields with NULL and assign empty gr_mem to known pointer
2509 rather than doing a pointless calloc. Streamline gr_mem parsing.
2510 Don't increment curr_lines here.
2511 * passwd.cc (pwdgrp::parse_passwd): Use new behavior of next_num.
2512 Don't increment curr_lines here.
2513 * uinfo.cc (pwdgrp::next_str): Keep returning EOL if out of data.
2514 (pwdgrp::reparse): Remove.
2515 (pwdgrp::next_num): Rename from next_int. Return bool indicating
2516 success of parse, argument returns value parsed.
2517 (pwdgrp::add_line): Increment curr_lines here on successful parse.
2518 (pwdgrp::load): (from Pierre Humblet) Don't return status. Just report
2519 it here.
2520
a53ddfe6
CF
25212003-01-25 Christopher Faylor <cgf@redhat.com>
2522
2523 * pwdgrp.cc (pwdgrp::reparse): Declare.
2524 * uinfo.cc (pwdgrp::reparse): Define.
c9b99d0d 2525 * grp.cc (pwdgrp::parse_group): Use reparse.
a53ddfe6 2526
4f7e12dd
CV
25272003-01-25 Pierre Humblet <pierre.humblet@ieee.org>
2528
2529 * syscalls.cc (seteuid32): On Win95 get the pw entry. If it exists
2530 update the euid and call cygheap->user.set_name. Remove special
2531 handling of ILLEGAL_UID.
ba6e1083 2532 (setgid32): Add a debug_printf. On Win95, always set the egid.
4f7e12dd
CV
2533 Remove special handling of ILLEGAL_GID. Do not compare gid and gr_gid.
2534 * child_info.h (class cygheap_exec_info): Remove uid.
2535 * spawn.cc (spawn_guts): Do not set ciresrv.moreinfo->uid.
2536 * dcrto.cc (dll_crt0_1): Always call uinfo_init.
2537 * uinfo.cc (uinfo_init): Reorganize and close handle if needed.
2538 (cygheap_user::ontherange): Do not call internal_getpwnam if pw is NULL.
2539
45dbfc26
CF
25402003-01-24 Christopher Faylor <cgf@redhat.com>
2541
2542 * fhandler_console.cc (fhandler_console::send_winch_maybe): Reset
2543 scroll region if size changes.
2544
7d33eefa
CV
25452003-01-24 Pierre Humblet <pierre.humblet@ieee.org>
2546 Jason Tishler <jason@tishler.net>
2547
2548 * cygwin.din: Export setreuid32, setreuid, setregid32, setregid.
2549 * syscalls.cc (setreuid32): New function.
2550 (setreuid): Ditto.
2551 (setregid32): Ditto.
2552 (setregid): Ditto.
2553 * include/cygwin/version.h: Bump API minor number.
2554
ac413374 25552003-01-23 Christopher Faylor <cgf@redhat.com>
69fae986 2556
ac413374 2557 * pwdrp.h (pwdgrp::refresh): Lock entire test prior to reading.
2037688a 2558
ac413374 25592003-01-23 Christopher Faylor <cgf@redhat.com>
09a88426
CF
2560
2561 * grp.cc (pwdgrp::parse_group): Eliminate arg and use class member
2562 instead. Use next_str and next_int to parse arguments.
2563 * passwd.cc (pwdgrp::parse_passwd): Ditto.
2564 (grab_string): Eliminate.
2565 (grab_int): Ditto.
2566 * pwdgrp.h (pwdgrp::parse): Eliminate input arg.
2567 (pwdgrp::parse_passwd): Reflect above change.
2568 (pwdgrp::parse_group): Reflect above change.
2569 (pwdgrp::next_str): New function.
2570 (pwdgrp::next_int): Ditto.
2571 (pwdgrp::gets): Eliminate.
2572 * uinfo.cc (pwdgrp::next_str): New function.
2573 (pwdgrp::next_int): Ditto.
2574 (pwdgrp::add_line): Subsume gets.
2575 (pwdgrp::gets): Eliminate.
2576 (pwdgrp::load): Just call add_line to parse input buffer.
2577
ac413374
CF
25782003-01-22 Thomas Pfaff <tpfaff@gmx.net>
2579
2580 * include/pthread.h (PTHREAD_MUTEX_RECURSIVE): Revert changes from
2581 2003-01-09 mutex patch.
2582 (PTHREAD_MUTEX_ERRORCHECK): Ditto.
2583
25842003-01-22 Corinna Vinschen <corinna@vinschen.de>
2585
2586 * cygrun.c: Move from here to ../testsuite.
2587 * Makefile.in: Remove cygrun.exe dependencies.
2588
25892003-01-21 Jason Tishler <jason@tishler.net>
2590
2591 * cygwin.din: Export nanosleep().
2592 * signal.cc (nanosleep): New function.
2593 (sleep): Move old functionality to nanosleep(). Call nanosleep().
2594 (usleep): Remove old functionality. Call nanosleep().
2595 * include/cygwin/version.h: Bump API minor number.
2596
57394495
CF
25972003-01-21 Christopher Faylor <cgf@redhat.com>
2598
2599 * grp.cc: Call gr.refresh() rather than doing isunitialized tests
2600 throughout.
2601 (gr): Use constructor (sigh).
2602 (pwdgrp::parse_group): Rename from parse_grp.
2603 (pwdgrp::read_group): Rename from read_etc_group. Just call gr.load
2604 with a single argument.
2605 * passwd.cc: Call pr.refresh() rather than doing isunitialized tests
2606 throughout.
2607 (pr): Use constructor (sigh).
2608 (pwdgrp::parse_passwd): Rename from "parse_pwd".
2609 (pwdgrp::read_passwd): Rename from read_etc_passwd. Just call pr.load
2610 with a single argument.
2611 * pwdgrp.h (pwdgrp_state): Eliminate.
2612 (pwdgrp): Reflect above renamings.
2613 (pwdgrp::etc_ix): Rename from pwd_ix.
2614 (pwdgrp::read): New element.
2615 (pwdgrp::lock): New element.
2616 (pwdgrp::refresh): New function.
2617 (pwdgrp::load): Eliminate variations which take buffer arguments.
2618 (pwdgrp::pwdgrp): New constructors. Initialize mutex here.
2619 * uinfo.cc (pwdgrp::load): Accommodate pwd_ix -> etc_ix renaming.
2620 (pwdgrp::load): Set initialized state to true rather than setting state
2621 to loaded.
2622
984864e9
CF
26232003-01-21 Christopher Faylor <cgf@redhat.com>
2624
89f7e8d1 2625 * include/cygwin/version.h: Bump DLL minor number.
984864e9 2626
d8cde3a3
CF
26272003-01-21 Pierre Humblet <pierre.humblet@ieee.org>
2628
2629 * path.h (etc::change_possible): Revert the type to bool.
2630 (etc::set_last_modified): Remove obsolete function.
2631 * path.cc (etc::change_possible): Revert type to bool.
2632 (etc::test_file_change): Do not test for negative values of
2633 change_possible and do not set it to -res.
2634 (etc::dir_changed): When the handle is NULL, call memset instead of
09a88426
CF
2635 test_file_changed. When the handle is invalid, return true. Detect
2636 filename change in /etc.
d8cde3a3 2637 (etc::file_changed): Remove unneeded check for !fn[n].
33de631b 2638 * uinfo.cc (pwdgrp::load): Eliminate spurious setting of fh to NULL.
b99b804b 2639 * pwdgrp.h (pwdgrp::operator =): Eliminate.
d8cde3a3 2640
7905c4f1
CF
26412003-01-19 Christopher Faylor <cgf@redhat.com>
2642
2643 * pwdgrp.h (etc): Move to path.h.
2644 (pwdgrp::max_lines): New field.
2645 (pwdgrp::curr_lines): New field.
2646 (pwdgrp::pwdgrp_buf): Ditto.
2647 (pwdgrp_buf_elem_size): Ditto.
2648 (pwdgrp_parse): Ditto.
2649 (pwdgrp::gets): Just declare here.
2650 (pwdgrp::load): Ditto. Just take one argument.
2651 (pwdgrp::load): Define overloaded function accepting passwd buf.
2652 (pwdgrp::load): Define overloaded function accepting group buf.
2653 * grp.cc: Use pwdgrp elements rather than standalone static variables
2654 throughout.
2655 (curr_lines): Eliminate.
2656 (max_lines): Ditto.
2657 (add_grp_line): Ditto.
2658 (parse_grp): Define as returning boolean. Accept void * arg and line
2659 count. Coerce first argument into __group32 buf reference. Increment
2660 curr_line as appropriate.
2661 (read_etc_group): Pass pwdgrp buffer to gr.load.
2662 * passwd.cc: Use pwdgrp elements rather than standalone static variables
2663 throughout.
2664 (curr_lines): Eliminate.
2665 (max_lines): Ditto.
2666 (add_grp_line): Ditto.
2667 (parse_passwd): Define as returning boolean. Accept void * arg and line
2668 count. Coerce first argument into passwd buf reference. Increment
2669 curr_line as appropriate.
2670 (read_etc_group): Pass pwdgrp buffer to pr.load.
2671 * path.cc (etc::fn): Extend buffer size to allow index by 1 rather than
2672 zero.
2673 (etc::last_modified): Ditto.
2674 (etc::change_possible): Ditto. Renamed from sawchange. Change to
2675 signed char since elements are now tri-state.
2676 (etc::init): Assume "handle" is 1 based rather than 0.
2677 (etc::test_file_change): New function. Sets change_possible based on
2678 file date comparison.
2679 (etc::dir_changed): Check file states immediately after changed_h is
2680 initialized to avoid a race.
2681 (etc::file_changed): Use test_file_change to detect if file needs to be
2682 updated.
2683 * path.h (etc): Move class here from pwdgrp.h.
7905c4f1
CF
2684 * uinfo.cc: Move etc:: functions to path.cc. Move pwdgrp functions
2685 here.
2686 (pwdgrp::gets): Eliminate buf checks. Just check eptr and set lptr.
2687 (pwdgrp::add_line): New function.
2688 (pwdgrp::load): Call generic add_line function which will call correct
2689 parser.
2690
4c6a3e50
CF
26912003-01-17 Christopher Faylor <cgf@redhat.com>
2692
2693 * cygheap.cc: Change most 'int's to 'unsigned's.
2694 (_cmalloc): Only check for size of malloced region when calculating
97d2bc79 2695 bucket. Add overhead when performing the sbrk. Previous change broke
4c6a3e50
CF
2696 _crealloc.
2697
e9152439
CF
26982003-01-17 Christopher Faylor <cgf@redhat.com>
2699
2700 * dcrt0.cc (initialize_env): Use colon for CYGWIN_DEBUG separator.
2701 * grp.cc: Change most statics to NO_COPY throughout.
2702 * passwd.cc: Ditto.
2703
27042003-01-17 Christopher Faylor <cgf@redhat.com>
2705
2706 * pwdgrp.h: Change some BOOLs to bools.
2707 (pwdgrp::pwdgrp): Remove unneeded constructor.
2708 * passwd.cc: Change BOOL to bool throughout.
2709
afa378e7
CV
27102003-01-17 Corinna Vinschen <corinna@vinschen.de>
2711
2712 * cygwin.din: Add strerror_r.
2713 * include/cygwin/version.h: Bump API minor number.
2714
1de6f431
CF
27152003-01-17 Christopher Faylor <cgf@redhat.com>
2716
2717 * uinfo.cc (etc::dir_changed): Don't print a warning if can't open
2718 /etc, unless debugging.
2719
d8cde3a3 27202003-01-17 Pierre Humblet <pierre.humblet@ieee.org>
14ea5029
CF
2721
2722 * grp.cc (read_etc_group): On NT, add a line for gid = -1. Change name
2723 "unknown" to "mkgroup".
2724 (internal_getgrgid): Do not return default in nontsec case.
2725 (internal_getgroups): Add argument srchsid and look for it in groups if
2726 not NULL.
2727 * passwd.cc (read_etc_passwd): On NT, add a line for uid = -1. Use
2728 same default uid for Win95 and NT. Call cygheap_user::ontherange to
2729 initialize HOME.
2730
14ea5029
CF
27312003-01-16 Christopher Faylor <cgf@redhat.com>
2732
2733 * cygheap.cc (init_cygheap::etc_changed): Move to uinfo.cc.
2734 * cygheap.h (init_cygheap::etc_changed_h): Remove.
2735 (init_cygheap::etc_changed): Ditto.
2736 * grp.cc (group_state): Remove. Use gr instead throughout.
2737 (gr): Define as class pwdgrp.
2738 (read_etc_group): Remove gr definition. Remove calls to
2739 set_last_modified and close. Pass add_grp to gr.load to load file.
2740 * passwd.cc (passwd_state): Remove. Use pr instead, throughout.
2741 (pr): Define as class pwdgrp.
2742 (read_etc_passwd): Remove pr definition. Remove calls to
2743 set_last_modified and close. Pass add_pwd_line to pr.load to load
2744 file.
2745 * pwdgrp.h (etc): New helper class for pwdgrp.
2746 (pwdgrp): Combine pwdgrp_check and pwdgrp_read into one class. Remove
2747 file_w32 and last_modified fields.
2748 (pwdgrp::set_last_modified): Remove.
2749 (pwdgrp::isinitializing): Remove FindFirstFile stuff. Move to
2750 etc::file_changed.
2751 (pwdgrp::load): Rename from 'open'. Call etc::init to initialize etc
2752 scanning. Close file handle after reading buffer into memory. Parse
2753 buffer by calling second argument.
2754 (pwdgrp::gets): Reorganize slightly to rely on eptr starting at
5304bcdf 2755 beginning of buffer.
14ea5029
CF
2756 (pwdgrp::close): Remove.
2757 * uinfo.cc (etc::dir_changed): New function.
2758 (etc::init): Ditto.
2759 (etc::file_changed): Ditto.
2760 (etc::set_last_modified): Ditto.
2761
41429bc9
CV
27622003-01-16 Jason Tishler <jason@tishler.net>
2763
2764 * mmap.cc (fixup_mmaps_after_fork): Add ERROR_NOACCESS to the list of
2765 ReadProcessMemory() error codes that trigger a retry with temporary
2766 PAGE_READONLY access. Note that this can occur on NT 4.0.
2767
18813254
CF
27682003-01-15 Christopher Faylor <cgf@redhat.com>
2769
2770 * path.cc (normalize_posix_path): Convert win32 path separators to
2771 slashes when full path is specified.
2772
77cb0c56
CF
27732003-01-15 Pierre Humblet <pierre.humblet@ieee.org>
2774
2775 * cmalloc.cc (_cmalloc): Fix memory leak.
2776
ce542f78
CV
27772003-01-15 Corinna Vinschen <corinna@vinschen.de>
2778
2779 * autoload.cc: Fix copyright date.
2780 * fhandler_dsp.cc: Ditto.
2781 * mmap.cc: Ditto.
2782 * net.cc: Ditto.
2783 * ntdll.h: Ditto.
2784 * signal.cc: Ditto.
2785 * syscalls.cc: Ditto.
2786 * uname.cc: Ditto.
2787 * wait.cc: Ditto.
2788
15996b6f
CV
27892003-01-14 Corinna Vinschen <corinna@vinschen.de>
2790
2791 * mmap.cc (fixup_mmaps_after_fork): Copy protection to child process.
2792 Change ambiguous debug output.
2793
857b65dd
CV
27942003-01-14 Corinna Vinschen <corinna@vinschen.de>
2795
2796 * mmap.cc (mmap_record::access): Change argument type to caddr_t
2797 for strictness.
2798 (mprotect): Protect against calling VirtualProtect() for shared
2799 pages on 9x/Me.
2800 (fixup_mmaps_after_fork): If ReadProcessMemory() fails, try to
2801 change protection of parent page to PAGE_READONLY, then try again.
2802 Revert protection afterwards.
2803
e14328f4
TP
28042003-01-14 Thomas Pfaff <tpfaff@gmx.net>
2805
2806 * syscalls.cc (system): Add pthread_testcancel call.
2807 * thread.cc: Update list of cancellation points.
2808
4a3584c8
TP
28092003-01-14 Thomas Pfaff <tpfaff@gmx.net>
2810
2811 * wait.cc: Include thread.h
2812 (wait4): Add pthread_testcancel call.
2813 Wait for child process and cancellation event.
2814 * thread.cc: Update list of cancellation points.
2815
7ec66a2c
TP
28162003-01-14 Thomas Pfaff <tpfaff@gmx.net>
2817
2818 * signal.cc (sleep): Add pthread_testcancel call.
2819 Wait for signal and cancellation event.
2820 (usleep): Ditto.
2821
28222003-01-14 Thomas Pfaff <tpfaff@gmx.net>
3457ce4d
TP
2823
2824 * exceptions.cc (handle_sigsuspend): Add pthread_testcancel call.
2825 Wait for signal and cancellation event.
2826 * thread.cc: Update list of cancellation points.
2827
2673d5f2
CF
28282003-01-14 David Huang <davehzhr@hotmail.com>
2829
2830 * fhandler_dsp.cc (fhandler_dsp::ioctl): Add limited support for
2831 SNDCTL_DSP_GETFMTS.
2832
9f0d3f37
CF
28332003-01-12 Christopher Faylor <cgf@redhat.com>
2834
2835 * ntdll.h: Fix typo.
2836
7f129d87
CV
28372003-01-12 Corinna Vinschen <corinna@vinschen.de>
2838
2839 * uname.cc (uname): Use cygwin_gethostname() to retrieve hostname.
2840
ab2dbccc
CV
28412003-01-12 Pierre Humblet <pierre.humblet@ieee.org>
2842
2843 * sec_acl.cc (search_ace): Use id == -1, instead of < 0, as wildcard.
2844 (setacl): Start the search for a matching default at the next entry.
2845 Invalidate the type of merged entries instead of clearing it.
2846 Use well_known_creator for default owner and owning group and do
2847 not try to merge non-default and default entries in these cases.
2848 (getacl): Recognize well_known_creator for default owner and group.
2849 (acl_worker): Improve errno settings and streamline the nontsec case.
2850 * security.cc (write_sd): Remove the call to set_process_privilege.
2851 (alloc_sd): If the owner changes, call set_process_privilege and return
2852 immediately on failure. Change inheritance rules: on new directories add
2853 inherit only allow ACEs for creator_owner, creator_group and everyone.
2854 Preserve all inheritances through chmod and chown calls. Introduce
2855 isownergroup to implement the uid == gid case, to keep the inheritance
2856 code simple. Do not initialize owner_sid and group_sid and stop using
2857 the variable psd.
2858
68115c74
CF
28592003-01-10 Christopher Faylor <cgf@redhat.com>
2860
2861 * net.cc: Use gethostname define from winsock2.h.
2862
e3abf986
CF
28632003-01-10 Christopher Faylor <cgf@redhat.com>
2864
2865 * path.cc: Unrevert below reversion except for
2866 mount_info::conv_to_posix_path part.
2867
df2caa88
CV
28682003-01-10 Corinna Vinschen <corinna@vinschen.de>
2869
2870 * path.cc: Revert patch from 2003-01-09 to normalize a windows path
2871 rather than converting to posix.
2872
dc8d11f5
CV
28732003-01-10 Corinna Vinschen <corinna@vinschen.de>
2874
2875 * autoload.cc (gethostname): Make call optional, return 1 if function
2876 can't get loaded.
2877 * net.cc (cygwin_gethostname): Call GetComputerName if return value
2878 of gethostname is non-zero.
2879
70d61f30
CV
28802003-01-10 Charles Wilson <cwilson@ece.gatech.edu>
2881
8735f49f 2882 * cygwin.din: Add asprintf and vasprintf, as well as the reentrant
70d61f30 2883 versions and underscore variants.
8735f49f 2884 * include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR.
70d61f30 2885
a7711767
CV
28862003-01-10 Corinna Vinschen <corinna@vinschen.de>
2887
2888 * net.cc (cygwin_gethostname): Fix call to wsock function gethostname.
2889
d5223b2b
CF
28902003-01-09 Christopher Faylor <cgf@redhat.com>
2891
2892 * cygthread.cc (cygthread::cygthread): Be more noisy about odd
2893 condition.
2894 * miscfuncs.cc (low_priority_sleep): Sleep in regular priority if
2895 that's what we're currently running at.
2896
65f207e8
TP
28972003-01-09 Thomas Pfaff <tpfaff@gmx.net>
2898
2899 * include/semaphore.h: Modify typedef for sem_t.
2900 * include/cygwin/types.h: Modify typedefs for pthread_t,
2901 pthread_mutex_t, pthread_key_t, pthread_attr_t,
2902 pthread_mutexattr_t, pthread_condattr_t, pthread_cond_t,
2903 pthread_rwlock_t and pthread_rwlockattr_t.
2904
09cbb9d6
TP
29052003-01-09 Thomas Pfaff <tpfaff@gmx.net>
2906
2907 * thread.h (WAIT_CANCELED): New define.
2908 (pthread::cancelable_wait): New static method.
2909 * thread.cc (pthread::cancelable_wait): Implement.
2910 (semaphore::Wait): Wait on semaphore and thread cancellation.
2911 (pthread::join): Wait on joined thread and thread cancellation.
2912 (semaphore::wait): Add testcancel to check for thread
2913 cancellation even if the semaphore is available.
2914
5d68d1de
TP
29152003-01-09 Thomas Pfaff <tpfaff@gmx.net>
2916
2917 * include/pthread.h: Add define for errorchecking mutexes.
2918 Change default mutex type.
2919 * thread.cc (pthread_cond::TimedWait): Update mutex unlock
2920 calls.
2921 (pthread_mutex::pthread_mutex): New implement.
2922 (pthread_mutex::~pthread_mutex): Ditto.
2923 (pthread_mutex::Lock): Ditto.
2924 (pthread_mutex::TryLock): Ditto.
2925 (pthread_mutex::UnLock): Ditto.
2926 (pthread_mutex::Destroy): Implement new method.
2927 (pthread_mutex::SetOwner): Ditto.
2928 (pthread_mutex::LockRecursive): Ditto.
2929 (pthread_mutex::fixup_after_fork): Restore locking state after
2930 fork.
2931 (__pthread_mutex_lock): Return pthread_mutex::Lock errorcode.
2932 (__pthread_mutex_trylock): Return pthread_mutex::TryLock
2933 errorcode.
2934 (__pthread_mutex_unlock): Return pthread_mutex::UnLock
2935 errorcode.
2936 (__pthread_mutex_destroy): Call pthread_mutex::Destroy to
3457ce4d 2937 destroy mutex.
5d68d1de
TP
2938 (__pthread_mutexattr_settype): Allow errorchecking and recursive
2939 types.
2940 * thread.h (MUTEX_LOCK_COUNTER_INITIAL): New define.
2941 (pthread_mutex::criticalsection): Remove.
2942 (pthread_mutex::lock_counter): New member.
2943 (pthread_mutex::recursion_counter): Ditto.
2944 (pthread_mutex::owner): Ditto.
2945 (pthread_mutex::type): Ditto.
2946 (pthread_mutex::Destroy): New method.
2947 (pthread_mutex::SetOwner): Ditto.
2948 (pthread_mutex::LockRecursive): Ditto.
2949
ed9fe455
TP
29502003-01-09 Thomas Pfaff <tpfaff@gmx.net>
2951
2952 * pthread.cc (pthread_cond_init): Use new pthread_cond::init.
2953 * thread.cc: Some white spaces cleanups.
2954 Change __pthread_cond_init to pthread_cond::init throughout.
2955 (nativeMutex): Move class methods outside pthread_mutex.
2956 (MTinterface::Init): Initialize pthread_cond init lock.
2957 (pthread_cond::condInitializationLock): Instantiate.
2958 (pthread_cond::initMutex): New Method.
2959 (pthread_cond::isGoodInitializerOrBadObject): Ditto.
2960 * thread.h: Some white spaces cleanups.
2961 (nativeMutex): Move class declaration outside pthread_mutex.
2962 (pthread_cond::condInitializationLock): New static member.
2963 (pthread_cond::initMutex): New Method.
2964 (pthread_cond::isGoodInitializerOrBadObject): Ditto.
2965 (__pthread_cond_init): Remove prototype.
2966
93353aee
CV
29672003-01-09 Corinna Vinschen <corinna@vinschen.de>
2968
2969 * fhandler_disk_file.cc (num_entries): Return 2 as link count if
2970 directory unreadable.
2971
3eb27a4e
CV
29722003-01-09 Corinna Vinschen <corinna@vinschen.de>
2973
2974 * security.cc (get_nt_attribute): Always return -1 when read_sd()
2975 fails.
2976 (get_file_attribute): Set permissions to 0 and owner/group to -1
2977 if security descriptor is unreadable.
2978
85ba109d
CF
29792003-01-09 Christopher Faylor <cgf@redhat.com>
2980
2981 Use isdirsep rather than SLASH_P throughout.
2982 * path.cc (iscygdrive): Disallow /cygdrive\x.
2983 (normalize_posix_path): "Normalize" a windows path, if detected, rather
2984 than converting to posix.
2985
29862003-01-06 Troy Curtiss <troyc@usa.net>
2987
2988 * fhandler_serial.cc (fhandler_serial::tcsetattr): Add support and
2989 capability checking for B230400 bitrate.
2990 (fhandler_serial::tcgetattr): Add support for B230400 bitrate.
2991 * include/sys/termios.h: Add B230400 definition for Posix support of
2992 230.4Kbps.
2993
cbdbe9d7
CF
29942003-01-05 Christopher Faylor <cgf@redhat.com>
2995
2996 * pinfo.cc (_pinfo::commune_send): Use myself->lock rather than just
2997 lock when leaving.
2998
f3afe99b
CF
29992003-01-03 Christopher Faylor <cgf@redhat.com>
3000
3001 * dtable.h (dtable::in_vfork_cleanup): New function. True if vfork
3002 cleanup needed.
3003 * dtable.cc (dtable::vfork_parent_restore): Remove assertion.
3004 * pipe.cc (fhandler_pipe::close): Don't close read_state during
3005 fork_fixup since it wasn't inherited.
3006
2665fb15
CF
30072003-01-01 Christopher Faylor <cgf@redhat.com>
3008
3009 * passwd.cc (getpwuid_r32): Revert previous change.
3010
8619b42b
CF
30112003-01-01 Christopher Faylor <cgf@redhat.com>
3012
3013 * sysconf.cc (sysconf): Return arbitrary values for
3014 _SC_GETGR_R_SIZE_MAX, _SC_LOGIN_NAME_MAX, _SC_GETPW_R_SIZE_MAX.
3015
3016 * passwd.cc (getpwuid_r32): Add uid/gid fields to size check
3017 calculation.
This page took 0.402067 seconds and 5 git commands to generate.