]> sourceware.org Git - newlib-cygwin.git/blame - winsup/cygwin/ChangeLog
* fhandler_socket.cc (SECRET_EVENT_NAME): Remove.
[newlib-cygwin.git] / winsup / cygwin / ChangeLog
CommitLineData
d4f3ce31
CV
12003-05-20 Corinna Vinschen <corinna@vinschen.de>
2
3 * fhandler_socket.cc (SECRET_EVENT_NAME): Remove.
4 (ENTROPY_SOURCE_NAME): Ditto.
5 (secret_event_name): New static function. Create shared event name
6 with "Global\" prefix on systems supporting terminal services.
7 (fhandler_socket::set_connect_secret): Fix conditional.
8 (fhandler_socket::create_secret_event): Create secret event using
9 secret_event_name().
10 (fhandler_socket::close_secret_event): Ditto.
11 * shared.cc (shared_name): Create shared object name with "Global\"
12 prefix on systems supporting terminal services.
13 * wincap.cc: Set has_terminal_services capability throughout.
14 (wincap_2003): New global object representing Windows 2003 Server
15 capabilities.
16 (wincapc::init): Accomodate Windows 2003 Server.
17 * wincap.h (struct wincaps): Add has_terminal_services capability.
18
10bada05
CV
192003-05-20 Charles Wilson <cygwin@cwilson.fastmail.fm>
20
21 * winsup/cygwin/include/cygwin/version.h: Bump API minor version.
22 * winsup/cygwin/include/cygwin/types.h: Define key_t as long long.
23 * winsup/cygwin/cygwin.din: Add ftok, _ftok.
24 * winsup/cygwin/ipc.cc (ftok): Rework implementation.
25
d8ee8ca5
CF
262003-05-18 Joe Buehler <jhpb@hekimian.com>
27
10bada05 28 * spawn.cc (spawn_guts): Show more of command line in strace output.
d8ee8ca5 29
c8fa3426
TP
302003-05-15 Thomas Pfaff <tpfaff@gmx.net>
31
32 * thread.h (pthread::init_mainthread): Remove function parameter.
33 (MTinterface::Init): Ditto.
34 * thread.cc (MTinterface::Init): Remove function parameter.
35 Always initialize reent_key.
36 (pthread::init_mainthread): Remove function parameter.
37 (MTinterface::fixup_after_fork): Fix pthread::init_mainthread call.
38 * dcrt0.cc (dll_crt_0_1) Fix calls to MTinterface::Init and
39 pthread::init_mainthread.
40 Call pthread::init_mainthread only when not forked.
41
f2669f5d
CV
422003-05-15 Corinna Vinschen <corinna@vinschen.de>
43
44 * fhandler_proc.cc (format_proc_meminfo): Make swap memory output
45 Linux style values.
46
5d575f7d
CV
472003-05-13 Corinna Vinschen <corinna@vinschen.de>
48
49 * include/cygwin/config.h: Define __USE_INTERNAL_STAT64 appropriately.
50
194d9eb3
CV
512003-05-12 Corinna Vinschen <corinna@vinschen.de>
52
53 * Makefile.in (CYGWIN_START): Define as crt0.o. Add to TARGET_LIBS.
54 * fhandler.h (fhandler_virtual::fstat): Remove useless declaration.
55 * fhandler_virtual.cc: Remove _COMPILING_NEWLIB define.
56 * ipc.cc (ftok): Use stat64.
57 * syscalls.cc (_fstat64): Remove alias.
58 (_fstat): Ditto.
59 (_stat): Ditto.
60 (_fstat64_r): New function.
61 (_fstat_r): Ditto.
62 (_stat64_r): Ditto.
63 (stat_r): Ditto.
64 * crt0.o: New file, moved from newlib.
65 * include/sys/param.h: Ditto.
66 * include/sys/utime.h: Ditto.
67 * include/sys/utmp.h: Ditto.
68 * include/sys/dirent.h: Ditto. Expose different struct dirent,
69 dependening of the environment.
70
cc95baad
CV
712003-05-11 Corinna Vinschen <corinna@vinschen.de>
72
73 Replace ino_t by __ino64_t throughout.
74
aee70853
CV
752003-05-11 Corinna Vinschen <corinna@vinschen.de>
76
77 * include/cygwin/types.h: Add key_t typedef.
78
066ca06f
CF
792003-05-10 Christopher Faylor <cgf@redhat.com>
80
81 * dir.cc (readdir): Fill out new old_d_ino field.
82 * fhandler.h (fhandler_base::namehash): Define as ino_t.
83 (fhandler_base::get_namehash): Ditto.
84 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Accommodate
85 new 64 bit st_ino.
86 * fhandler_socket.cc (fhandler_socket::fstat): Ditto.
87 * path.cc (hash_path_name): Return ino_t.
88 * syscalls.cc (stat64_to_stat32): Convert 64 bit inode to 32 bit.
89 * winsup.h (hash_path_name): Declare as returning ino_t.
90 * include/cygwin/stat.h (__stat32): Use 32 bit st_ino.
91 (__stat64): Use 64 bit st_ino.
92 * include/cygwin/types.h (__ino64_t): Define.
93 (__ino32_t): Ditto.
94 (ino_t): Define appropriately.
95
3e66a81c
CV
962003-05-10 Corinna Vinschen <corinna@vinschen.de>
97
98 * Makefile.in (NEW_FUNCTIONS): All 32/64 from 0.79 API get
99 leading underscore.
100 * cygwin.din: Ditto.
101 * include/cygwin/version.h: Bump API minor number.
102
d3b450f3
CV
1032003-05-09 Corinna Vinschen <corinna@vinschen.de>
104
105 * include/cygwin/config.h: New file.
106
9508ebc5
CF
1072003-05-09 Christopher Faylor <cgf@redhat.com>
108
109 * cygthread.cc (cygthread::detach): Prioritize waiting for I/O
110 completion over waiting for signal delivery.
111
0bb7254f
TP
1122003-05-06 Thomas Pfaff <tpfaff@gmx.net>
113
114 * signal.cc (nanosleep): Do not wait twice for signal arrival.
115
a6d745f5
CV
1162003-05-03 Corinna Vinschen <corinna@vinschen.de>
117
118 * include/cygwin/types.h: Fix erroneous definition of ino_t from
119 2003-04-28.
120
40d3c804
CV
1212003-05-03 Corinna Vinschen <corinna@vinschen.de>
122
123 * syscalls.cc (chown_worker): Allow chown'ing of socket files.
124
2238537c
TP
1252003-04-30 Thomas Pfaff <tpfaff@gmx.net>
126
127 * Makefile.in: Revert patch from 2003-04-17.
128
6ef342e4
CF
1292003-04-28 Brian Ford <ford@vss.fsi.com>
130
131 * profil.h (PROFADDR): Prevent overflow when text segments are larger
132 than 256k.
133 * profil.c (profthr_func): Raise thread priority for more accurate
134 sampling.
135
1362003-04-26 Christopher Faylor <cgf@redhat.com>
137
138 * path.cc (hash_path_name): Use ino_t as type.
139
7d6d38aa
CF
1402003-04-26 Christopher Faylor <cgf@redhat.com>
141
142 * errno.cc (_sys_nerr): Fix compile error erroneously checked in on
143 2003-04-23.
144
f615d74b
CV
1452003-04-25 Corinna Vinschen <corinna@vinschen.de>
146
147 * include/netinet/ip.h: Include netinet/in_systm.h and netinet/in.h
148 to allow standalone usage (autoconf).
149
5d9a7c87
CF
1502003-04-23 Christopher Faylor <cgf@redhat.com>
151
152 * fork.cc: Change SLOW_PID_REUSE to NO_SLOW_PID_REUSE and invert ifdef
153 sense throughout.
154
0eaf24fe
CF
1552003-04-22 Christopher Faylor <cgf@redhat.com>
156
157 * select.cc (fhandler_pipe::ready_for_read): Assure that get_guard is
158 called for successful non-blocking pipe reads.
159
e8a57b4f
CV
1602003-04-22 Corinna Vinschen <corinna@vinschen.de>
161
162 * include/inttypes.h: New file.
163 * include/stdint.h: New file.
164 * include/cygwin/in.h: Include stdint.h instead of sys/types.h.
165 * include/cygwin/types.h: Include stdint.h. Remove typedefs for
166 intN_t and uintN_t since these are defined in stdint.h now.
167
99b1a40d
CF
1682003-04-21 Christopher Faylor <cgf@redhat.com>
169
650dc784 170 * include/cygwin/version.h: Bump DLL major number to 1005. Change DLL
99b1a40d
CF
171 minor number to 0. Bump API minor number.
172
beb54085
CV
1732003-04-20 Corinna Vinschen <corinna@vinschen.de>
174
175 * autoload.cc (CreateWindowStationA): Add.
176 (SetProcessWindowStation): Add.
177
6b3bdf38
CF
1782003-04-19 Christopher Faylor <cgf@redhat.com>
179
180 * wincap.h (wincaps:pty_needs_alloc_console): New element.
181 (wincapc:pty_needs_alloc_console): New function.
182 * wincap.cc: Add pty_needs_alloc_console throughout.
183 * fhandler_tty.cc (fhandler_tty_slave::open): Open an "invisible"
184 console on first pty allocation.
185
afa18d8a
CF
1862003-04-18 Christopher Faylor <cgf@redhat.com>
187
188 * fhandler_tty.cc (fhandler_tty_slave::open): Allocate a console
189 whenever a pty is allocated.
190
4e0d8778
CF
1912003-04-18 Christopher Faylor <cgf@redhat.com>
192
193 * Makefile.in: Use ${nostdlib} variable.
194
1952003-04-18 Diego Biurrun <diego@biurrun.de>
196
197 * fhandler_proc.cc (format_proc_cpuinfo): Change /proc/cpuinfo "vendor
198 id" string to "vendor_id" to conform with Linux systems.
199
4e837e73
CF
2002003-04-17 Christopher Faylor <cgf@redhat.com>
201
202 * syscalls.cc (setsid): Don't call FreeConsole if ctty is already < 0.
203
f3c1c540
TP
2042003-04-17 Thomas Pfaff <tpfaff@gmx.net>
205
206 * Makefile.in: Add finline-functions optimization to CXXFLAGS.
207 * autoload.cc (LoadDLLprime): Rename std_dll_init to
208 _std_dll_init.
209 (std_dll_init): Remove name mangling prototype. Add attributes
210 used and noinline.
211 (wsock_init): Ditto.
212 Change wsock_init to _wsock_init in wsock32 and ws2_32
213 LoadDLLprime.
214 * exceptions.cc (unused_sig_wrapper): Remove prototype. Add
215 attributes used and noinline.
216 * pwdgrp.h ((pwdgrp (passwd *&)): Remove inline code.
217 (pwdgrp (__group32 *&)): Ditto.
218 * grp.cc (pwdgrp (passwd *&)): Outline constructor.
219 (pwdgrp (__group32 *&)): Ditto.
220
a4cea440
TP
2212003-04-17 Thomas Pfaff <tpfaff@gmx.net>
222
223 * thread.h (pthread::equal): New static method.
224 * thread.cc: Rename pthread_equal to pthread::equal throughout.
225 (pthread_equal): Use pthread::equal to compare threads ids.
226
c448f78f
CF
2272003-04-15 Christopher Faylor <cgf@redhat.com>
228
229 * termios.cc (setspeed): New function.
230 (cfsetospeed): Use setspeed to set speed.
231 (cfsetispeed): Use setspeed to set speed.
232
2332003-04-15 Chris January <chris@atomice.net>
234
235 * autoload.cc: Add load statement for UuidCreate, and
236 UuidCreateSequential.
237 * cpuid.h: New file.
238 * cygwin.din: Export gethostid.
239 * fhandler_proc.cc (cpuid): Move to cpuid.h.
240 (can_set_flag): Move to cpuid.h.
241 * syscalls.cc (gethostid): New function.
5f92bef8 242 * version.h: Bump api minor version number to 83.
c448f78f 243
ffb576fb
TP
2442003-04-15 Thomas Pfaff <tpfaff@gmx.net>
245
246 * thread.h (pthread_rwlock::release): New method.
c448f78f
CF
247 * thread.cc (pthread_rwlock::unlock): Use release to signal waiting
248 threads.
ffb576fb
TP
249 (pthread_rwlock::rdlock_cleanup): Signal waiting threads after a
250 cancelation.
251 (pthread_rwlock::wrlock_cleanup): Ditto.
252
b3acb772
CF
2532003-04-13 Pierre Humblet <pierre.humblet@ieee.org>
254
255 * mkvers.sh: Prefix day with 0 in date only when day < 10.
256
2e23862a
CV
2572003-04-11 Pierre Humblet <pierre.humblet@ieee.org>
258
259 * security.cc (get_info_from_sd): New function.
260 (get_nt_attribute): Only call read_sd and get_info_from_sd.
261 Return void.
262 (get_file_attribute): Move sd error handling to get_info_from_sd.
263 and symlink handling to fhandler_disk_file::fstat_helper.
264 (get_nt_object_attribute): Only call read_sd and get_info_from_sd.
265 Return void.
266 (get_object_attribute): Remove symlink handling and simply return -1
267 when ntsec is off.
268 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): For
269 symlinks set the attribute, call get_file_attribute to get the ids
270 and return. In the normal case call get_file_attribute with the
271 addresses of the buffer ids and do not recheck if the file is a socket.
272
73afb2ab
CF
2732003-04-10 Christopher Faylor <cgf@redhat.com>
274
275 * cygthread.cc (cygthread::stub): Initialize stack pointer earlier.
276 (cygthread::simplestub): Initialize stack pointer.
277 (cygthread::terminate_thread): Account for possibility that stack
278 pointer has not been set. Issue warnings for unusual conditions.
279
2a1e8e11
CV
2802003-04-10 Corinna Vinschen <corinna@vinschen.de>
281
282 * regex/regex.h: Define regoff_t as _off_t.
283 * regex/regex2.h: Ditto.
284
ac5ec961
CV
2852003-04-10 Corinna Vinschen <corinna@vinschen.de>
286
287 * cygwin.din: Export wcscoll, wcswidth and wcwidth.
288 * include/cygwin/version.h: Bump API minor number.
289
e5d6d535
CF
2902003-04-10 Christopher Faylor <cgf@redhat.com>
291
292 * cygthread.h: Change 'avail' cygthread element to 'inuse' throughout.
293 * cygthread.cc: Ditto.
294 (cygthread::stub): Don't initialize already initialized events.
295 (cygthread::freerange): Don't create thread here.
296 (cygthread::cygthread): Create thread here. Die if thread not created.
297 (cygthread::operator new): Simplify. Just grab a thread structure from
298 the pool. Don't try to start the thread.
299 (cygthread::terminate_thread): Don't close event handles. Just reuse
d8ee8ca5 300 them. Call MEM_RELEASE rather than MEM_DECOMMIT (from Joe uehler).
e5d6d535 301
ca81cd60
CF
3022003-04-08 Bob Cassels <bcassels@abinitio.com>
303
304 * fhandler_console.cc (fhandler_console::read) Handle certain key up
305 events, to allow pasting accented characters and typing them using the
306 "alt + numerics" sequences.
307
3082003-04-07 Christopher Faylor <cgf@redhat.com>
309
310 * include/limits.h (IOV_MAX): Set to a number which is small enough to
311 use in an array.
312
b410f168
CF
3132003-04-04 Christopher Faylor <cgf@redhat.com>
314
9dbe3289
CF
315 * cygthread.h (cygthread::avail): Make LONG for easier use with
316 Interlocked* functions.
317 * cygthread.cc (cygthread::init): Eliminate unneeded muto.
318 (cygthread::operator new): Don't lock. Instead change use of avail
319 variable into tri-state: available (1), not available (-1),
320 uninitialized (0).
321 (cygthread::terminate_thread): Set avail to uninitialized.
322 (cygthread::detach): Eliminate local 'avail'. Always set avail to 1
323 unless signalled.
324
3252003-04-04 Christopher Faylor <cgf@redhat.com>
326
327 * cygthread.cc (cygthread::operator new): Be more defensive when messing with
b410f168
CF
328 threads that are marked "unavailable".
329
a61bf8c3
CF
3302003-04-03 Christopher Faylor <cgf@redhat.com>
331
332 * fhandler_console.cc (CONVERT_LIMIT): Use a size for the 21st century.
333
d5292d66
CV
3342003-04-03 Corinna Vinschen <corinna@vinschen.de>
335
336 * external.cc (check_ntsec): Return general ntsec state on NULL
337 filename. Check wincap.is_security() additionally.
338
5a87c616
CF
3392003-04-02 Christopher Faylor <cgf@redhat.com>
340
341 * Makefile.in (EXTRA_OFILES): Remove debugging object.
342
d99c6176
CF
3432003-04-02 Jason Tishler <jason@tishler.net>
344 Christopher Faylor <cgf@redhat.com>
345
346 * external.cc (check_ntsec): New function.
347 (cygwin_internal): Add CW_CHECK_NTSEC handling to call check_ntsec()
348 from applications.
349 * include/cygwin/version.h: Bump API minor number.
350 * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_CHECK_NTSEC.
351
3522003-04-02 Christopher Faylor <cgf@redhat.com>
353
354 * cygthread.cc (cygthread::new): Add more defensive debugging.
355
2d388e43 3562003-04-01 Pierre Humblet <pierre.humblet@ieee.org>
d99c6176 357
2d388e43
CV
358 * fhandler.cc (fhandler_base::fstat): Set the uid and gid fields
359 from the current effective ids.
360 * fhandler_socket.cc (fhandler_socket::fstat): Keep the uid and gid set
361 by fhandler_base::fstat.
362 * security.cc (get_nt_attribute): Do not test wincap.has_security ().
363 (get_nt_object_attribute): Ditto.
364 (get_file_attribute): Add test for wincap.has_security ().
365 (get_object_attribute): Ditto.
366
1727fba0
CV
3672003-04-01 Corinna Vinschen <corinna@vinschen.de>
368
369 * dir.cc: Change __off32_t to _off_t and __off64_t to _off64_t
370 throughout.
371 * fhandler.cc: Ditto.
372 * fhandler.h: Ditto.
373 * fhandler_clipboard.cc: Ditto.
374 * fhandler_disk_file.cc: Ditto.
375 * fhandler_dsp.cc: Ditto.
376 * fhandler_floppy.cc: Ditto.
377 * fhandler_mem.cc: Ditto.
378 * fhandler_proc.cc: Ditto.
379 * fhandler_process.cc: Ditto.
380 * fhandler_random.cc: Ditto.
381 * fhandler_registry.cc: Ditto.
382 * fhandler_tape.cc: Ditto.
383 * fhandler_termios.cc: Ditto.
384 * fhandler_virtual.cc: Ditto.
385 * fhandler_zero.cc: Ditto.
386 * mmap.cc: Ditto.
387 * pipe.cc: Ditto.
388 * syscalls.cc: Ditto.
389 * winsup.h: Ditto.
390 * include/cygwin/stat.h: Ditto.
391 * include/cygwin/types.h: Ditto. Remove definition of __off32_t
392 and __off64_t.
393
333879e7
CF
3942003-03-31 Christopher Faylor <cgf@redhat.com>
395
396 * exceptions.cc (setup_handler): Make sure winapi lock is released when
397 exiting loop.
398
a2105d93
CF
3992003-03-30 Christopher Faylor <cgf@redhat.com>
400
401 * include/cygwin/fs.h: Remove unneeded include.
402 * include/cygwin/in.h: Include sys/types.h rather than cygwin/types.h.
403
856a9750
CV
4042003-03-29 Corinna Vinschen <corinna@vinschen.de>
405
406 * syscalls.cc (login): Fix comment.
407 (logout): Ditto.
408
8304de2e
CV
4092003-03-29 Corinna Vinschen <corinna@vinschen.de>
410
411 * syscalls.cc: Slightly cleanup all utmp functions.
412 (login): Use mutex to secure against concurrent access to wtmp file.
413 (logout): Rewrite using POSIX calls.
414 (utmp_fd): Initialized to -1 now. Any value < 0 is treated as closed
415 in subsequent functions.
416 (utmp_readonly): New variable, indicating utmp file open for reading
417 only.
418 (internal_setutent): New function implementing setutent().
419 (setutent): Call internal_setutent now.
420 (endutent): Reset utmp_readonly.
421 (getutent): Return immediately if utmp file can't be opened.
422 (getutid): Ditto.
423 (getutline): Ditto.
424 (pututline): Ditto. Use mutex to secure against concurrent access to
425 utmp file.
426
46c8214c
CF
4272003-03-28 Christopher Faylor <cgf@redhat.com>
428
429 * Makefile.in: Remove EXE_LDFLAGS. Fix fhandler_CFLAGS typo. Recognize .s suffix.
430 * configure.in: Remove EXE_LDFLAGS.
431 * configure: Regenerate.
432
a7ab35c1
CF
4332003-03-28 Christopher Faylor <cgf@redhat.com>
434
435 * include/sys/cygwin.h: Declare cygwin_internal as unsigned long.
436 * external.cc (cygwin_internal): Define as unsigned long.
437
4382003-03-27 Christopher Faylor <cgf@redhat.com>
439
440 * include/sys/cygwin.h: Move cygwin_internal outside of WINVER
441 conditional.
442
eff6c00e
TP
4432003-03-27 Thomas Pfaff <tpfaff@gmx.net>
444
445 * thread.cc: Change 1==foo equations to foo==1 throughout.
446
15648790
TP
4472003-03-27 Thomas Pfaff <tpfaff@gmx.net>
448
449 * thread.h: Change class names, methods, members and local vars
450 according to the GNU coding style.
451 * thread.cc: Ditto.
452 * dcrt0.cc (dll_crt0_1): Rename pthread::initMainThread call to
453 pthread::init_mainthread.
454 * pthread.cc (pthead_getsequence_np): Rename pthread::isGoodObject
455 call to pthread::is_good_object.
456
98b36ec8
CV
4572003-03-27 Joe Buehler <jhpb@draco.hekimian.com>
458
1ce82d24
CF
459 * autoload.cc: Add RegGetKeySecurity().
460 * security.cc (get_nt_object_attribute): Use RegGetKeySecurity() for
98b36ec8
CV
461 performance.
462
85738bf7
CF
4632003-03-25 Christopher Faylor <cgf@redhat.com>
464 Joe Buehler <jhpb@draco.hekimian.com>
465
466 * fork.cc (fork_parent): Don't copy signals from parent to child here.
467 * sigproc.cc (proc_subproc): Copy signals from parent to child pinfo
468 here.
469
9306ba2e
TP
4702003-03-23 Thomas Pfaff <tpfaff@gmx.net>
471
85738bf7
CF
472 * thread.h (class List): Move inline code inside class declaration.
473 (List::forEach): Change callback parameter to template class member
474 function pointer.
475 (pthread_keys::fixup_before_fork): Change to inline. Use List::forEach
476 to fixup keys.
9306ba2e
TP
477 (pthread_keys::fixup_after_fork): Ditto.
478 (pthread_keys::runAllDestructors): Ditto.
479 (pthread_key::saveAKey): Remove.
480 (pthread_key::restoreAKey): Ditto.
481 (pthread_key::destroyAKey): Ditto.
482 (pthread_key::run_destructor): Rename to runDestructor.
85738bf7
CF
483 (pthread_mutex::fixup_after_fork): Change to inline. Use List::forEach
484 to fixup mutexes after a fork.
9306ba2e
TP
485 (pthread_mutex::FixupAfterFork): New method.
486 (pthread_mutex::mutexes): New member.
85738bf7
CF
487 (pthread_cond::fixup_after_fork): Change to inline. Use List::forEach
488 to fixup conds after a fork.
9306ba2e
TP
489 (pthread_cond::FixupAfterFork): New method.
490 (pthread_cond::conds): New member.
85738bf7 491 (pthread_rwlock::fixup_after_fork): Change to inline. Use
9306ba2e
TP
492 List::forEach to fixup rwlocks after a fork.
493 (pthread_rwlock::FixupAfterFork): New method.
494 (pthread_rwlock::rwlocks): New member.
85738bf7
CF
495 (semaphore::fixup_after_fork): Change to inline. Use List::forEach to
496 fixup mutexes after a fork.
9306ba2e
TP
497 (semaphore::FixupAfterFork): New method.
498 (semaphore::semaphores): New member.
499 (MTinterface::mutexs): Remove.
500 (MTinterface::conds): Ditto.
501 (MTinterface::rwlocks): Ditto.
502 (MTinterface::semaphores): Ditto.
503 (pthread_equal): Add extern "C".
504 (pthread_mutex_lock): Ditto.
85738bf7
CF
505
506 * thread.cc (MTinterface::fixup_after_fork): Change fixup_after_fork
507 calls for pthread objects.
9306ba2e 508 (semaphore::conds): Instantiate.
85738bf7
CF
509 (pthread_cond::pthread_cond): Use List::Insert rather than custom list
510 code.
511 (pthread_cond::~pthread_cond): Use List::Remove rather than custom list
512 code.
9306ba2e
TP
513 (pthread_cond::fixup_after_fork): Rename to FixupAfterFork.
514 (pthread_rwlock::rwlocks): Instantiate.
85738bf7
CF
515 (pthread_rwlock::pthread_crwlock): Use List::Insert rather than custom
516 list code.
517 (pthread_rwlock::~pthread_rwlock): Use List::Remove rather than custom
518 list code.
9306ba2e
TP
519 (pthread_rwlock::fixup_after_fork): Rename to FixupAfterFork.
520 (pthread_key::saveAKey): Remove.
521 (pthread_key::fixup_before_fork): Ditto.
522 (pthread_key::restoreAKey): Ditto.
523 (pthread_key::fixup_after_fork): Ditto.
524 (pthread_key::destroyAKey): Ditto.
525 (pthread_key::runAllDestructors): Ditto.
526 (pthread_key::run_destructor): Rename to runDestructor.
527 (pthread_mutex::mutexes): Instantiate.
85738bf7
CF
528 (pthread_mutex::pthread_mutex): Use List::Insert rather than custom
529 list code.
530 (pthread_mutex::~pthread_mutex): Use List::Remove rather than custom
531 list code.
9306ba2e
TP
532 (pthread_mutex::fixup_after_fork): Rename to FixupAfterFork.
533 (semaphore::conds): Instantiate.
85738bf7
CF
534 (semaphore::semaphore): Use List::Insert rather than custom list code.
535 (semaphores::~semaphore): Use List::Remove rather than custom list
9306ba2e 536 code.
9306ba2e
TP
537 (semaphore::fixup_after_fork): Rename to FixupAfterFork.
538
ff3ef36d
CF
5392003-03-22 Christopher Faylor <cgf@redhat.com>
540
541 * pipe.cc (fhandler_pipe::dup): Don't dup input_handle if it doesn't
542 exist.
543
ca04f61f
CF
5442003-03-22 Christopher Faylor <cgf@redhat.com>
545
546 * syscalls.cc (unlink): Be more defensive when SetFileAttributes is
547 called. Fix typo in debugging output.
548
89e7a1ce
CF
5492003-03-21 Christopher Faylor <cgf@redhat.com>
550
551 * fork.cc: Conditionalize use of slow_pid_reuse throughout. It's not
552 necessary for newer versions of bash.
553
fa85038b
CV
5542003-03-20 Corinna Vinschen <corinna@vinschen.de>
555
556 * fhandler_socket.cc (fhandler_socket::sendto): Restrict EPIPE and
557 SIGPIPE handling to connection oriented sockets. Add comment.
558
4da34970
CF
5592003-03-19 Christopher Faylor <cgf@redhat.com>
560
561 * sigproc.h (signal_fixup_after_exec): Eliminate argument in declaration.
562 * exceptions.cc (signal_fixup_after_exec): Eliminate argument in
563 definition. Don't reset signal handlers after spawm. Just treat like
564 fork/exec.
565 * dcrt0.cc (dll_crt0_1): Don't pass PROC_SPAWN argument to
566 signal_fixup_after_exec.
567 * syscalls.cc (unlink): Don't change attributes of file if not readonly/system.
568 Ditto for resetting of arguments.
569
036ac6b3
CV
5702003-03-19 Corinna Vinschen <corinna@vinschen.de>
571
572 * glob.c: Eliminate __INSIDE_CYGWIN__ preprocessor conditionals
573 throughout.
574
b1897d27
CV
5752003-03-19 Corinna Vinschen <corinna@vinschen.de>
576
577 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Fix
578 wrong usage of S_IFDIR.
579 * security.cc (get_attribute_from_acl): Ditto.
580 (get_file_attribute): Fix wrong usage of S_IFLNK.
581 (get_object_attribute): Ditto.
582 (alloc_sd): Fix wrong usage of S_IFDIR.
583 * syscalls.cc (chmod): Allow chmod'ing of socket files.
584
c16d0946
CV
5852003-03-19 Corinna Vinschen <corinna@vinschen.de>
586
587 * include/cygwin/version.h (CYGWIN_VERSION_CHECK_FOR_USING_BIG_TYPES):
588 Define.
589 * glob.c (g_lstat): Use CYGWIN_VERSION_CHECK_FOR_USING_BIG_TYPES
590 instead of numerical constants.
591 (g_stat): Ditto.
592
6a80a133
TP
5932003-03-18 Thomas Pfaff <tpfaff@gmx.net>
594
595 * pthread.cc (pthread_attr_init): Remove
596 (pthread_attr_destroy): Ditto.
597 (pthread_attr_setdetachstate): Ditto.
598 (pthread_attr_getdetachstate): Ditto.
599 (pthread_attr_setstacksize): Ditto.
600 (pthread_attr_getstacksize): Ditto.
601 (pthread_attr_setinheritsched): Ditto.
602 (pthread_attr_getinheritsched): Ditto.
603 (pthread_attr_setschedparam): Ditto.
604 (pthread_attr_getschedparam): Ditto.
605 (pthread_attr_setschedpolicy): Ditto.
606 (pthread_attr_getschedpolicy): Ditto.
607 (pthread_attr_setscope): Ditto.
608 (pthread_attr_getscope): Ditto.
609 (pthread_attr_setstackaddr): Ditto.
610 (pthread_attr_getstackaddr): Ditto.
611 (pthread_key_create): Ditto.
612 (pthread_key_delete): Ditto.
613 (pthread_setspecific): Ditto.
614 (pthread_getspecific): Ditto.
615 (pthread_kill): Ditto.
616 (pthread_sigmask): Ditto.
617 (pthread_equal): Ditto.
618 (pthread_mutex_lock): Ditto.
619 (pthread_mutex_trylock): Ditto.
620 (pthread_mutex_unlock): Ditto.
621 (pthread_mutex_destroy): Ditto.
622 (pthread_mutex_setprioceiling): Ditto.
623 (pthread_mutex_getprioceiling): Ditto.
624 (pthread_mutexattr_destroy): Ditto.
625 (pthread_mutexattr_getprioceiling): Ditto.
626 (pthread_mutexattr_getprotocol): Ditto.
627 (pthread_mutexattr_getpshared): Ditto.
628 (pthread_mutexattr_gettype): Ditto.
629 (pthread_mutexattr_init): Ditto.
630 (pthread_mutexattr_setprioceiling): Ditto.
631 (pthread_mutexattr_setprotocol): Ditto.
632 (pthread_mutexattr_setpshared): Ditto.
633 (pthread_mutexattr_settype): Ditto.
634 (pthread_cond_destroy): Ditto.
635 (pthread_cond_signal): Ditto.
636 (pthread_cond_broadcast): Ditto.
637 (pthread_condattr_init): Ditto.
638 (pthread_condattr_destroy): Ditto.
639 (pthread_condattr_getpshared): Ditto.
640 (pthread_condattr_setpshared): Ditto.
641 (pthread_rwlock_destroy): Ditto.
642 (pthread_rwlock_rdlock): Ditto.
643 (pthread_rwlock_tryrdlock): Ditto.
644 (pthread_rwlock_wrlock): Ditto.
645 (pthread_rwlock_trywrlock): Ditto.
646 (pthread_rwlock_unlock): Ditto.
647 (pthread_rwlockattr_init): Ditto.
648 (pthread_rwlockattr_getpshared): Ditto.
649 (pthread_rwlockattr_setpshared): Ditto.
650 (pthread_rwlockattr_destroy): Ditto.
651 (pthread_getconcurrency): Ditto.
652 (pthread_setconcurrency): Ditto.
653 (pthread_getschedparam): Ditto.
654 (pthread_setschedparam): Ditto.
655
656 * thread.h (__pthread_attr_init): Remove prototype.
657 (__pthread_attr_destroy): Ditto.
658 (__pthread_attr_setdetachstate): Ditto.
659 (__pthread_attr_getdetachstate): Ditto.
660 (__pthread_attr_setstacksize): Ditto.
661 (__pthread_attr_getstacksize): Ditto.
662 (__pthread_attr_setinheritsched): Ditto.
663 (__pthread_attr_getinheritsched): Ditto.
664 (__pthread_attr_setschedparam): Ditto.
665 (__pthread_attr_getschedparam): Ditto.
666 (__pthread_attr_setschedpolicy): Ditto.
667 (__pthread_attr_getschedpolicy): Ditto.
668 (__pthread_attr_setscope): Ditto.
669 (__pthread_attr_getscope): Ditto.
670 (__pthread_attr_setstackaddr): Ditto.
671 (__pthread_attr_getstackaddr): Ditto.
672 (__pthread_key_create): Ditto.
673 (__pthread_key_delete): Ditto.
674 (__pthread_setspecific): Ditto.
675 (__pthread_getspecific): Ditto.
676 (__pthread_kill): Ditto.
677 (__pthread_sigmask): Ditto.
678 (__pthread_equal): Ditto.
679 (__pthread_mutex_lock): Ditto.
680 (__pthread_mutex_trylock): Ditto.
681 (__pthread_mutex_unlock): Ditto.
682 (__pthread_mutex_destroy): Ditto.
683 (__pthread_mutex_setprioceiling): Ditto.
684 (__pthread_mutex_getprioceiling): Ditto.
685 (__pthread_mutexattr_destroy): Ditto.
686 (__pthread_mutexattr_getprioceiling): Ditto.
687 (__pthread_mutexattr_getprotocol): Ditto.
688 (__pthread_mutexattr_getpshared): Ditto.
689 (__pthread_mutexattr_gettype): Ditto.
690 (__pthread_mutexattr_init): Ditto.
691 (__pthread_mutexattr_setprioceiling): Ditto.
692 (__pthread_mutexattr_setprotocol): Ditto.
693 (__pthread_mutexattr_setpshared): Ditto.
694 (__pthread_mutexattr_settype): Ditto.
695 (__pthread_cond_destroy): Ditto.
696 (__pthread_cond_signal): Ditto.
697 (__pthread_cond_broadcast): Ditto.
698 (__pthread_condattr_init): Ditto.
699 (__pthread_condattr_destroy): Ditto.
700 (__pthread_condattr_getpshared): Ditto.
701 (__pthread_condattr_setpshared): Ditto.
702 (__pthread_rwlock_destroy): Ditto.
703 (__pthread_rwlock_rdlock): Ditto.
704 (__pthread_rwlock_tryrdlock): Ditto.
705 (__pthread_rwlock_wrlock): Ditto.
706 (__pthread_rwlock_trywrlock): Ditto.
707 (__pthread_rwlock_unlock): Ditto.
708 (__pthread_rwlockattr_init): Ditto.
709 (__pthread_rwlockattr_getpshared): Ditto.
710 (__pthread_rwlockattr_setpshared): Ditto.
711 (__pthread_rwlockattr_destroy): Ditto.
712 (__pthread_getconcurrency): Ditto.
713 (__pthread_setconcurrency): Ditto.
714 (__pthread_getschedparam): Ditto.
715 (__pthread_setschedparam): Ditto.
716
717 * thread.cc: Rename __pthread_equal to pthread_equal throughout.
718 Change pthread_self parameter appropriate.
719 (__pthread_attr_init): Remove __ prefix. Change to extern "C".
720 (__pthread_attr_destroy): Ditto.
721 (__pthread_attr_setdetachstate): Ditto.
722 (__pthread_attr_getdetachstate): Ditto.
723 (__pthread_attr_setstacksize): Ditto.
724 (__pthread_attr_getstacksize): Ditto.
725 (__pthread_attr_setinheritsched): Ditto.
726 (__pthread_attr_getinheritsched): Ditto.
727 (__pthread_attr_setschedparam): Ditto.
728 (__pthread_attr_getschedparam): Ditto.
729 (__pthread_attr_setschedpolicy): Ditto.
730 (__pthread_attr_getschedpolicy): Ditto.
731 (__pthread_attr_setscope): Ditto.
732 (__pthread_attr_getscope): Ditto.
733 (__pthread_attr_setstackaddr): Ditto.
734 (__pthread_attr_getstackaddr): Ditto.
735 (__pthread_key_create): Ditto.
736 (__pthread_key_delete): Ditto.
737 (__pthread_setspecific): Ditto.
738 (__pthread_getspecific): Ditto.
739 (__pthread_kill): Ditto.
740 (__pthread_sigmask): Ditto.
741 (__pthread_equal): Ditto.
742 (__pthread_mutex_lock): Ditto.
743 (__pthread_mutex_trylock): Ditto.
744 (__pthread_mutex_unlock): Ditto.
745 (__pthread_mutex_destroy): Ditto.
746 (__pthread_mutex_setprioceiling): Ditto.
747 (__pthread_mutex_getprioceiling): Ditto.
748 (__pthread_mutexattr_destroy): Ditto.
749 (__pthread_mutexattr_getprioceiling): Ditto.
750 (__pthread_mutexattr_getprotocol): Ditto.
751 (__pthread_mutexattr_getpshared): Ditto.
752 (__pthread_mutexattr_gettype): Ditto.
753 (__pthread_mutexattr_init): Ditto.
754 (__pthread_mutexattr_setprioceiling): Ditto.
755 (__pthread_mutexattr_setprotocol): Ditto.
756 (__pthread_mutexattr_setpshared): Ditto.
757 (__pthread_mutexattr_settype): Ditto.
758 (__pthread_cond_destroy): Ditto.
759 (__pthread_cond_signal): Ditto.
760 (__pthread_cond_broadcast): Ditto.
761 (__pthread_condattr_init): Ditto.
762 (__pthread_condattr_destroy): Ditto.
763 (__pthread_condattr_getpshared): Ditto.
764 (__pthread_condattr_setpshared): Ditto.
765 (__pthread_rwlock_destroy): Ditto.
766 (__pthread_rwlock_rdlock): Ditto.
767 (__pthread_rwlock_tryrdlock): Ditto.
768 (__pthread_rwlock_wrlock): Ditto.
769 (__pthread_rwlock_trywrlock): Ditto.
770 (__pthread_rwlock_unlock): Ditto.
771 (__pthread_rwlockattr_init): Ditto.
772 (__pthread_rwlockattr_getpshared): Ditto.
773 (__pthread_rwlockattr_setpshared): Ditto.
774 (__pthread_rwlockattr_destroy): Ditto.
775 (__pthread_getconcurrency): Ditto.
776 (__pthread_setconcurrency): Ditto.
777 (__pthread_getschedparam): Ditto.
778 (__pthread_setschedparam): Ditto.
779
00d296a3
TP
7802003-03-18 Thomas Pfaff <tpfaff@gmx.net>
781
782 * cygwin.din: Add pthread_rwlock_destroy, pthread_rwlock_init,
783 pthread_rwlock_rdlock, pthread_rwlock_tryrdlock,
784 pthread_rwlock_wrlock, pthread_rwlock_trywrlock,
785 pthread_rwlock_unlock, pthread_rwlockattr_init,
786 pthread_rwlockattr_getpshared, pthread_rwlockattr_setpshared,
787 and pthread_rwlockattr_destroy.
788 * include/cygwin/version.h: Bump API minor number.
789 * include/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Define a
790 reasonable value.
791 Add prototypes for pthread_rwlock_destroy, pthread_rwlock_init,
792 pthread_rwlock_rdlock, pthread_rwlock_tryrdlock,
793 pthread_rwlock_wrlock, pthread_rwlock_trywrlock,
794 pthread_rwlock_unlock, pthread_rwlockattr_init,
795 pthread_rwlockattr_getpshared, pthread_rwlockattr_setpshared,
796 and pthread_rwlockattr_destroy.
797 * thread.h (PTHREAD_ONCE_MAGIC): Remove superflous semicolon.
798 (PTHREAD_RWLOCK_MAGIC): New define.
799 (PTHREAD_RWLOCKATTR_MAGIC): Ditto.
800 (pthread_rwlockattr): New class.
801 (pthread_rwlock): Ditto.
802 (MTinterface::rwlocks): New member.
803 (MTinterface::MTinterface): Initialize rwlocks.
804 Add prototypes for __pthread_rwlock_destroy,
805 __pthread_rwlock_wrlock, __pthread_rwlock_trywrlock,
806 __pthread_rwlock_unlock, __pthread_rwlockattr_init,
807 __pthread_rwlockattr_getpshared, __pthread_rwlockattr_setpshared,
808 and __pthread_rwlockattr_destroy.
809 * thread.cc (MTinterface::Init): Initialize rwlock internal mutex.
810 (MTinterface::fixup_after_fork): Fixup rwlocks after fork.
811 (pthread_rwlockattr::isGoodObject): Implement.
812 (pthread_rwlockattr::pthread_rwlockattr): Ditto.
813 (pthread_rwlockattr::~pthread_rwlockattr): Ditto.
814 (pthread_rwlock::initMutex): Ditto.
815 (pthread_rwlock::pthread_rwlock): Ditto.
816 (pthread_rwlock::~pthread_rwlock): Ditto.
817 (pthread_rwlock::RdLock): Ditto.
818 (pthread_rwlock::TryRdLock): Ditto.
819 (pthread_rwlock::WrLock): Ditto.
820 (pthread_rwlock::TryWrLock): Ditto.
821 (pthread_rwlock::UnLock): Ditto.
822 (pthread_rwlock::addReader): Ditto.
823 (pthread_rwlock::removeReader): Ditto.
824 (pthread_rwlock::lookupReader): Ditto.
825 (pthread_rwlock::RdLockCleanup): Ditto.
826 (pthread_rwlock::WrLockCleanup): Ditto.
827 (pthread_rwlock::fixup_after_fork): Ditto.
828 (pthread_rwlock::isGoodObject): Ditto.
829 (pthread_rwlock::isGoodInitializer): Ditto.
830 (pthread_rwlock::isGoodInitializerOrObject): Ditto.
831 (pthread_rwlock::isGoodInitializerOrBadObject): Ditto.
832 (__pthread_rwlock_destroy): Ditto.
833 (pthread_rwlock::init): Ditto.
834 (__pthread_rwlock_rdlock): Ditto.
835 (__pthread_rwlock_tryrdlock): Ditto.
836 (__pthread_rwlock_wrlock): Ditto.
837 (__pthread_rwlock_trywrlock): Ditto.
838
f592b05d
TP
8392003-03-18 Thomas Pfaff <tpfaff@gmx.net>
840
841 * thread.h (pthread_cond::ExitingWait): Remove.
842 (pthread_cond::mutex): Ditto.
843 (pthread_cond::cond_access): Ditto.
844 (pthread_cond::win32_obj_id): Ditto.
845 (pthread_cond::TimedWait): Ditto.
846 (pthread_cond::BroadCast): Ditto.
847 (pthread_cond::Signal): Ditto.
848 (pthread_cond::waiting): Change type to unsigned long.
849 (pthread_cond::pending): New member.
850 (pthread_cond::semWait): Ditto.
851 (pthread_cond::mtxIn): Ditto.
852 (pthread_cond::mtxOut): Ditto.
853 (pthread_cond::mtxCond): Ditto.
854 (pthread_cond::UnBlock): New method.
855 (pthread_cond::Wait): Ditto.
856 * thread.cc: Update list of cancellation points.
857 (pthread_cond::pthread_cond): Rewrite.
858 (pthread_cond::~pthread_cond): Ditto.
859 (pthread_cond::TimedWait): Remove.
860 (pthread_cond::BroadCast): Ditto.
861 (pthread_cond::Signal): Ditto.
862 (pthread_cond::UnBlock): Implement.
863 (pthread_cond::Wait): Ditto.
864 (pthread_cond::fixup_after_fork): Rewrite.
865 (pthread_mutex::fixup_after_fork): Remove DETECT_BAD_APP
866 conditional.
867 (__pthread_cond_broadcast): Just return 0 if the condition is
868 not initialized. Call pthread_cond::UnBlock to release blocked
869 threads.
870 (__pthread_cond_signal): Ditto.
871 (__pthread_cond__dowait): Rewrite.
872 (pthread_cond_timedwait): Add pthread_testcancel call. Fix
873 waitlength calculation.
874 (pthread_cond_wait): Add pthread_testcancel call.
875
2ff03dc2
TP
8762003-03-18 Thomas Pfaff <tpfaff@gmx.net>
877
878 * include/pthread.h (PTHREAD_MUTEX_NORMAL): New define.
879 * thread.cc: Remove errno.h include.
880 (pthread::precreate): Change internal mutex type to normal.
881 (pthread_mutex::canBeUnlocked): Implement.
882 (pthread_mutex::pthread_mutex): Initialize lock_counter with 0.
883 (pthread_mutex::Lock): Rename to _Lock. Add self parameter.
884 Change lock_counter logic. Update SetOwner call.
885 (pthread_mutex::TryLock): Rename to _TryLock. Add self parameter.
886 Change lock_counter logic. Update SetOwner call.
887 (pthread_mutex::UnLock): Rename to _UnLock. Add self parameter.
888 Change lock_counter logic.
889 (pthread_mutex::Destroy): Rename to _Destroy. Update TryLock call.
890 (pthread_mutex::SetOwner): Move to thread.h as inline.
891 (pthread_mutex::LockRecursive): Ditto.
892 (pthread_mutex::fixup_after_fork): Change lock_counter logic.
893 (__pthread_mutexattr_settype): Add PTHREAD_MUTEX_NORMAL to valid
894 types check.
895 * thread.h: Include errno.h and limits.h.
896 (MUTEX_LOCK_COUNTER_INITIAL): Remove.
897 (MUTEX_OWNER_ANONYMOUS): New define.
898 (pthread_mutex::canBeUnlocked): New static method.
899 (pthread_mutex::lock_counter): Change type to unsigned long.
900 (pthread_mutex::GetPthreadSelf): New method.
901 (pthread_mutex::Lock): Call _Lock with pthread_self pointer.
902 (pthread_mutex::TryLock): Call _TryLock with pthread_self pointer.
903 (pthread_mutex::UnLock): Call _UnLock with pthread_self pointer.
904 (pthread_mutex::Destroy): Call _Destroy with pthread_self pointer.
905 (pthread_mutex::SetOwner): Moved from thread.cc as inline.
906 (pthread_mutex::LockRecursive): Ditto.
907 (pthread_mutex::_Lock): New method.
908 (pthread_mutex::_TryLock): New method.
909 (pthread_mutex::_UnLock): New method.
910 (pthread_mutex::_Destroy): New method.
911
dcd350f0
CV
9122003-03-18 Christopher January <chris@atomice.net>
913
914 * fhandler_proc.cc (format_proc_cpuinfo): Use IsProcessorFeaturePresent
915 only on Windows NT. Read CPU Mhz value only on NT. Revert previous
916 change so cpuid instruction is called even on non-NT systems.
917
c51dc9c2
CV
9182003-03-17 Corinna Vinschen <corinna@vinschen.de>
919
a2105d93 920 * glob.c (g_lstat): Change API minor test to match API minor number
c51dc9c2
CV
921 change in previous patch.
922 (g_stat): Ditto.
923
f194ba1f
CF
9242003-03-17 Christopher Faylor <cgf@redhat.com>
925
926 * include/cygwin/version.h: Reorganize last two api versions so that
927 btowc and trunc exports show up before previous bump since there has
928 been no exported version of the DLL with the 64 bit changes yet but
929 1.3.22 will have the btowc and trunc.
930
3543669f
CF
9312003-03-17 Christopher Faylor <cgf@redhat.com>
932
933 * cygwin.din: Export btowc, trunc.
934 * include/cygwin/version.h: Reflect new exports.
935 * syscalls.cc (_stat): Rename to stat to avoid newlib wrapper.
936 * syscalls.cc (_fstat): Ditto.
937
9382003-03-16 Christopher Faylor <cgf@redhat.com>
939
940 * fhandler_console.cc (fhandler_console::close): Correct check for
941 current tty. Add debugging output when console is freed.
942 (set_console_state_for_spawn): Add debugging output.
943 * fhandler_tty.cc (fhandler_tty_slave::open): Don't decrement console
944 open flag when vforking.
945 * sigproc.cc (sigproc_terminate): Fix debugging output.
946 * spawn.cc (handle): Eliminate second argument.
947 (spawn_guts): Reflect elimination of argument change to handle.
948 * syscalls.cc (setsid): Add debugging output when console is freed.
949
9502003-03-14 Christopher Faylor <cgf@redhat.com>
951
952 * syscalls.cc (rename): Revert assumption that DELETE_ON_CLOSE works on
953 Win9x.
954
41ffdfa5
CF
9552003-03-13 Christopher Faylor <cgf@redhat.com>
956
957 * include/cygwin/version.h: Bump DLL minor number to 23.
958
5b186cd9
CV
9592003-03-13 Corinna Vinschen <corinna@vinschen.de>
960
961 * autoload.cc (IsProcessorFeaturePresent): Add.
962 * fhandler_proc.cc (format_proc_cpuinfo): Add case for 9x systems.
963
c58555c7
CV
9642003-03-13 Corinna Vinschen <corinna@vinschen.de>
965
966 * fhandler_proc.cc (format_proc_cpuinfo): Fix vendor id in cpuid case.
967
49a0d53c
CV
9682003-03-13 Corinna Vinschen <corinna@vinschen.de>
969
970 * net.cc (cygwin_rcmd): Use correct file descriptor in call to fdsock.
971 (cygwin_rexec): Ditto.
972
6fcd5661
CF
9732003-03-13 Christopher Faylor <cgf@redhat.com>
974
975 * fhandler_tty.cc (fhandler_tty_slave::close): Fix typo in debug
976 output.
977
978 * syscalls.cc (rename): Assume that DELETE_ON_CLOSE works on Win9x.
979
aa39b7f7
CV
9802003-03-11 Corinna Vinschen <corinna@vinschen.de>
981
982 * fhandler_socket.cc (fhandler_socket::dup): Don't call
983 fhandler_base::dup() but call DuplicateHandle directly instead to have
984 control over socket inheritence.
985
2afa7f58
CV
9862003-03-11 Corinna Vinschen <corinna@vinschen.de>
987
988 * fhandler_socket.cc (fhandler_socket::dup): On NT systems avoid
989 using WinSock2 socket duplication methods. Add comment.
990
9912003-03-11 Pierre Humblet <pierre.humblet@ieee.org>
992
993 * fhandler_socket.cc (fhandler_socket::fixup_after_fork):
994 Set io_handle to INVALID_SOCKET in case of failure.
995 (fhandler_socket::dup): Return 0 if the io_handle is valid.
996
556ceaeb
CV
9972003-03-10 Corinna Vinschen <corinna@vinschen.de>
998
999 * sec_acl.cc (setacl): Don't handle DELETE flag specially.
1000 * security.cc (alloc_sd): Ditto.
1001
a201401c
CV
10022003-03-09 Corinna Vinschen <corinna@vinschen.de>
1003
6bbf711e 1004 * winver.rc: Change Copyright hint to include 2003.
a201401c 1005
b1aae492
CV
10062003-03-09 Corinna Vinschen <corinna@vinschen.de>
1007
1008 Switch to 32/64 datatypes:
1009 * Makefile.in (OBSOLETE_FUNCTIONS): Add open acl aclcheck aclfrommode
1010 aclfrompbits aclfromtext aclsort acltomode acltopbits acltotext chown
1011 facl fchown fgetpos fopen freopen fseeko fsetpos fstat ftello
1012 ftruncate getegid geteuid getgid getgrent getgrgid getgrnam getgroups
1013 getpwuid getpwuid_r getuid initgroups lchown lseek lstat mknod mmap
1014 seekdir setegid seteuid setgid setgroups setregid setreuid setuid stat
1015 telldir truncate.
1016 (NEW_FUNCTIONS): Add _open64 acl32 aclcheck32 aclfrommode32
1017 aclfrompbits32 aclfromtext32 aclsort32 acltomode32 acltopbits32
1018 acltotext32 chown32 facl32 fchown32 fgetpos64 fopen64 freopen64
1019 fseeko64 fsetpos64 fstat64 ftello64 ftruncate64 getegid32 geteuid32
1020 getgid32 getgrent32 getgrgid32 getgrnam32 getgroups32 getpwuid32
1021 getpwuid_r32 getuid32 initgroups32 lchown32 lseek64 lstat64 mknod32
1022 mmap64 seekdir64 setegid32 seteuid32 setgid32 setgroups32 setregid32
1023 setreuid32 setuid32 stat64 telldir64 truncate64 to substitute the
1024 above.
1025 * cygserver_shm.h (class client_request_shm): Change uid_t and gid_t
1026 members to __uid32_t and __gid32_t.
1027 * cygwin.din: Add symbols acl32 aclcheck32 aclfrommode32
1028 aclfrompbits32 aclfromtext32 aclsort32 acltomode32 acltopbits32
1029 acltotext32 facl32 fgetpos64 fopen64 freopen64 fseeko64 fsetpos64
1030 _fstat64 ftello64 _lseek64 mknod32 _open64.
1031 * glob.c: Include perprocess.h.
1032 (globtilde): Call getpwuid32 and getuid32 instead of getpwuid and
1033 getuid.
1034 (g_lstat): Check for applications API version to call the appropriate
1035 typed gl_lstat function.
1036 (g_stat): Ditto for gl_stat.
1037 * shm.cc (client_request_shm::client_request_shm): Call geteuid32
1038 and getegid32 instead of geteuid and getegid throughout.
1039 * syscalls.cc (_open64): New alias for open.
1040 (_lseek64): New alias for lseek64.
1041 (_fstat64): New alias for fseek64.
1042 (mknod32): New function.
1043 (mknod): Calls mknod32 now.
1044 * winsup.h: Make function declarations for getuid32, geteuid32,
1045 and getpwuid32 accessible for plain C sources. Add declarations
1046 for getegid32 and getpwnam.
1047 * include/cygwin/version.h: Bum API minor number to 78.
1048 * include/sys/cygwin.h: Guard C++ specific members of struct
1049 per_process against inclusion in plain C sources.
1050 * include/sys/mman.h (mman): Add guard to avoid type clash when
1051 compiling Cygwin.
1052
659fb3ff
CF
10532003-03-09 Christopher Faylor <cgf@redhat.com>
1054
d580d86c 1055 * include/cygwin/version.h: Bump DLL minor number to 22.
659fb3ff 1056
c367dfd0
CF
10572003-03-09 Christopher Faylor <cgf@redhat.com>
1058
1059 Do some minor reformatting of 'extern "C"' use throughout.
1060
10612003-03-06 Christopher January <chris@atomice.net>
1062
1063 * autoload.cc (GetSystemTimes): Define new autoload function.
1064 * fhandler_proc.cc (proc_listing): Add cpuinfo and partitions entries.
1065 (fhandler_proc::fill_filebuf): Add PROC_CPUINFO and PROC_PARTITIONS
1066 cases.
1067 (format_proc_uptime): Use GetSystemTimes if available.
1068 (read_value): New macro.
1069 (print): New macro.
1070 (cpuid): New function.
1071 (can_set_flag): New function.
1072 (format_proc_cpuinfo): New function.
1073 (format_proc_partitions): New function.
1074
36c4a441
CF
10752003-03-09 Christopher Faylor <cgf@redhat.com>
1076
1077 * syscalls.cc (unlink): Attempt to be more clever about setting
1078 attributes of file. Only open file in query mode to avoid having to
1079 mess with security stuff for reading.
1080
639ebe29
CV
10812003-03-09 Corinna Vinschen <corinna@vinschen.de>
1082
1083 * rmsym: Fix regular expression.
1084
3a1d827f
CF
10852003-03-09 Christopher Faylor <cgf@redhat.com>
1086
1087 * Makefile.in: Change from using new-* to cygwin0 for temporary
1088 targets.
1089
ca0e9071
CV
10902003-03-09 Corinna Vinschen <corinna@vinschen.de>
1091
1092 * include/cygwin/socket.h: Set SOMAXCONN to Winsock2 value.
1093
ed269cea
CF
10942003-03-08 Christopher Faylor <cgf@redhat.com>
1095
1096 * syscalls.cc (unlink): Always attempt to use FILE_FLAG_CLOSE_ON_DELETE
1097 to delete files since this allows us to preserve the protection of hard
1098 linked files.
1099 (link): Generate full path for potentially recalculated .lnk target.
1100
1114c3d0
CF
11012003-03-08 Christopher Faylor <cgf@redhat.com>
1102
1103 Revert below changes regarding _pinfo::cmdline.
1104
d66ac2bc
CV
11052003-03-08 Corinna Vinschen <corinna@vinschen.de>
1106
1107 * external.cc (cygwin_internal): Change n to __off64_t to match change
1108 of _pinfo::cmdline.
1109 * fhandler.h (class fhandler_virtual): Change filesize member to
1110 __off64_t.
1111 * fhandler_proc.cc (format_proc_meminfo): Change to return __off64_t.
1112 (format_proc_stat): Ditto.
1113 (format_proc_uptime): Ditto.
1114 * fhandler_process.cc (format_process_stat): Ditto.
1115 (format_process_status): Ditto.
1116 (format_process_statm): Ditto.
1117 * pinfo.cc (_pinfo::cmdline): Expect __off64_t parameter.
1118 * pinfo.h (class _pinfo): Change declaration of cmdline accordingly.
1119
762520f3
CF
11202003-03-07 Christopher Faylor <cgf@redhat.com>
1121
1122 * path.h (PATH_LNK): New enum val.
1123 (path_conv::is_lnk_symlink): New function. True if path represents
1124 .lnk style symlink.
1125 * path.cc (check_shortcut): Set PATH_LNK in pflags when appropriate.
1126 (symlink_info::check): Ditto. Remove PATH_LNK from pflags initially.
1127 * syscalls.cc (unlink): Always remove readonly attribute from a symlink
1128 regardless of type.
1129 (link): (from Corinna Vinschen) Allow links to symlinks. Reset
1130 attributes on a symlink after successful link creation.
1131 (chmod): Use is_lnk_symlink where appropriate.
1132 (rename): Ditto.
1133
11342003-03-07 Pierre Humblet <pierre.humblet@ieee.org>
1135
1136 * tty.cc (create_tty_master): Call GetComputerName instead of
1137 cygwin_gethostname. Set ut_id.
1138 * syscalls.cc (login): Call endutent.
1139 (setutent): Do not seek after a fresh open.
1140
6f8102cb
CV
11412003-03-07 Corinna Vinschen <corinna@vinschen.de>
1142
1143 * syscalls.cc (seteuid32): Fix formatting.
1144
88243328
TP
11452003-03-04 Thomas Pfaff <tpfaff@gmx.net>
1146
1147 * thread.cc (MTinterface::fixup_after_fork): Initialize mainthread
1148 prior to pthread objects.
762520f3 1149
12390bc4
CV
11502003-03-04 Jason Tishler <jason@tishler.net>
1151
1152 * fhandler_socket.cc (fhandler_socket::dup): Initialize type.
1153
c418817e
CF
11542003-03-03 Christopher Faylor <cgf@redhat.com>
1155
1156 * fhandler.h (fhandler_tty_slave::close): Declare new function.
1157 (fhandler_tty_slave::dup): Declare new function.
1158 (fhandler_tty_slave::fixup_after_function): Declare new function.
1159 * fhandler_tty.cc (fhandler_tty_slave_open): Only increment
1160 fhandler_console::open_fhs when associated with a pty.
1161 (fhandler_tty_slave::close): Define new function. Decrement
1162 fhandler_console::open_fhs when associated with a pty.
1163 (fhandler_tty_slave::dup): Define new function. Increment
1164 fhandler_console::open_fhs when associated with a pty.
1165 (fhandler_tty_slave::fixup_after_fork): Define new function. Increment
1166 fhandler_console::open_fhs when associated with a pty.
1167
e11fe31b
CF
11682003-03-03 Christopher Faylor <cgf@redhat.com>
1169
1170 * fhandler_tty.cc (fhandler_pty_slave::open): Grudgingly increment
1171 fhandler_console::open_fhs here.
1172 (fhandler_pty_slave::close): Ditto for close.
1173
cffdb4b1
CF
11742003-03-02 Christopher Faylor <cgf@redhat.com>
1175
1176 * lib/getopt.c: Refresh from NetBSD sources.
1177
d5d2ffee
CF
11782003-03-02 Christopher Faylor <cgf@redhat.com>
1179
1180 * fhandler_console.cc (fhandler_console::close): Don't decrement
1181 in use counter if in vfork fixup stage.
1182
c2c6b170
CF
11832003-03-02 Christopher Faylor <cgf@redhat.com>
1184
1185 * lib/getopt.c: Nuke use of unneeded BSDisms.
1186
8b19b43d
CF
11872003-03-02 Christopher Faylor <cgf@redhat.com>
1188
1189 * dll_init.cc (dll_list::load_after_fork): Don't revert to LoadLibrary
1190 if LoadLibraryEx fails.
1191 * dtable.cc (dtable::dec_console_fds): Eliminate.
1192 (dtable::release): Don't treat console specially.
1193 (dtable::build_fhandler): Ditto.
1194 * dtable.h (console_fds): Eliminate.
1195 (dtable::dec_console_fds): Eliminate.
1196 (dtable::inc_console_fds): Eliminate.
1197 * fhandler.h (fhandler_console::open_fhs): New static element.
1198 * fhandler_console.cc (fhandler_console::open): Increment open_fs.
1199 (fhandler_console::close): Call FreeConsole if no more open consoles
1200 and ctty is not associated with the console.
1201 * syscalls.cc (setsid): Simplify check for when to call FreeConsole.
1202 (check_pty_fds): Eliminate definition.
1203 * winsup.h (check_pty_fds): Eliminate declaration.
1204
3efc65f7
CF
12052003-03-02 Christopher Faylor <cgf@redhat.com>
1206
1207 * dll_init.cc (dll_list::load_after_fork): Fix typo where result of
1208 LoadLibrary was ignored.
1209
5a082e9e
CV
12102003-03-01 Corinna Vinschen <corinna@vinschen.de>
1211
1212 * fhandler_socket.cc (fhandler_socket::bind): Open and write socket
1213 file using Win32 calls.
1214
9d913f07
CV
12152003-03-01 Corinna Vinschen <corinna@vinschen.de>
1216
1217 * fhandler_socket.cc (get_inet_addr): Open and read socket file using
1218 Win32 calls.
1219
005c3065
CF
12202003-02-28 Christopher Faylor <cgf@redhat.com>
1221
1222 * cygwin.din: Wrap atexit and exit with cygwin, thread-safe functions.
1223 * dcrt0.cc (cygwin_atexit): New function.
1224 (cygwin_exit): Ditto.
1225
27b4082a
PH
12262003-02-28 Pierre Humblet <pierre.humblet@ieee.org>
1227
1228 * syscalls.cc (fstat64): Pass get_name () to pc.
005c3065 1229 (access): Pass fn to stat_worker.
27b4082a
PH
1230
12312003-03-27 Corinna Vinschen <corinna@vinschen.de>
5777b970
CV
1232
1233 * fhandler_socket.cc (class sock_event): New class managing Winsock
1234 events for interruptible socket calls.
1235 (fhandler_socket::connect): Move support for interruptible call to
1236 class sock_event. Use class object instead.
1237 (fhandler_socket::accept): Ditto. Remove useless casts.
1238
005c3065 12392003-03-27 Thomas Pfaff <tpfaff@gmx.net>
5777b970
CV
1240
1241 * fhandler_socket.cc (fhandler_socket::connect): Add support for
1242 an interruptable connect.
1243
7b2ce663
CV
12442003-02-27 Pierre Humblet <pierre.humblet@ieee.org>
1245
1246 * uinfo.cc (internal_getlogin): Only update user.groups.pgsid
1247 if the call to set the primary group succeeds.
1248
0e7a60fe
CF
12492003-02-27 Christopher Faylor <cgf@redhat.com>
1250
1251 * cygthread::detach: Improve error message.
1252
61a52599
CV
12532003-02-26 Pierre Humblet <pierre.humblet@ieee.org>
1254
1255 * sec_helper.cc (get_sids_info): debug_print owner_sid and group_sid.
1256
6b9a9ce6
CV
12572003-02-25 Corinna Vinschen <corinna@vinschen.de>
1258
1259 * mmap.cc (mmap64): Fix returned address by taking the granularity
1260 into account.
1261
1ffc44aa
PH
12622003-02-23 Pierre Humblet <pierre.humblet@ieee.org>
1263
1264 * syslog.cc (syslog): Do not unlock the file before closing it
1265 and remove debug_printf about stream errors.
1266
a066f364
CF
12672003-02-22 Christopher Faylor <cgf@redhat.com>
1268
1269 * cygmalloc.h: Remove MORECORE_CANNOT_TRIM. It's not true.
1270 # cygwin.din: Export mallinfo.
1271 # malloc_wrapper.cc (mallinfo): New function.
1272
878e60c5
CF
12732003-02-22 Pierre Humblet <pierre.humblet@ieee.org>
1274
1275 * syslog.cc (syslog): Do not print the Windows pid. Print the Cygwin
1276 pid as an unsigned decimal. On Win95 print a timestamp and attempt to
1277 lock the file up to four times in 3 ms.
1278
b1d1e50d
CV
12792003-02-21 Corinna Vinschen <corinna@vinschen.de>
1280
1281 * fhandler_socket.cc (fhandler_socket::fhandler_socket): Fix compiler
1282 warning.
1283 (fhandler_socket::fstat): Simplify. Set st_uid/st_gid to effective
1284 uid/gid of current process in case of open sockets.
1285
cf762b08
CV
12862003-02-21 Corinna Vinschen <corinna@vinschen.de>
1287
1288 * dtable.cc (dtable::build_fhandler_from_name): Set some fhandler
1289 data on sockets to evaluate AF_LOCAL sockets correctly.
1290 (dtable::build_fhandler): Set unit number on sockets.
1291 * fhandler.h (fhandler_socket): Add unit number.
1292 (fhandler_socket::get_unit): New method.
1293 * fhandler_socket.cc (fhandler_socket::fhandler_socket): Set unit
1294 number.
1295 (fhandler_socket::fstat): Reorganize to return more Linux-like
1296 values.
1297 * net.cc: include ctype.h.
1298 (fdsock): Set unit number when building fhandler.
1299 * path.cc (path_conv::check): Set device type to FH_SOCKET if file
1300 is a AF_UNIX socket.
1301 (get_devn): Evaluate unit for virtual socket devices.
1302 (win32_device_name): Set windows path for sockets to unix_path with
1303 just backslashes to keep the different names.
1304 * syscalls.cc (fstat64): Don't override st_ino, st_dev and st_rdev
1305 for sockets.
1306 (stat_worker): Ditto.
1307
13082003-02-21 Pierre Humblet <pierre.humblet@ieee.org>
1309
1310 * autoload.cc (AccessCheck): Add.
1311 (DuplicateToken): Add.
1312 * security.h (check_file_access): Declare.
1313 * syscalls.cc (access): Convert path to Windows, check existence
1314 and readonly attribute. Call check_file_access instead of acl_access.
1315 * security.cc (check_file_access): Create.
1316 * sec_acl (acl_access): Delete.
1317
5cd82412
CF
13182003-02-19 Christopher Faylor <cgf@redhat.com>
1319
1320 * fhandler.cc (fhandler_base::open): Move some filesystem specific
1321 stuff.
1322 (fhandler_disk_file::open): Accept some filesystem specific stuff.
1323 * sigproc.cc (wait_for_sigthread): Become slightly more thread safe.
1324 (sig_send): Don't assume that signal thread is ready.
1325
892d8962
CV
13262003-02-20 Corinna Vinschen <corinna@vinschen.de>
1327
1328 * wincap.h (wincap): Remove unnecessary definition of
1329 supports_sparse_files.
1330 * wincap.cc: Ditto.
1331
518f5d49
CV
13322003-02-20 Corinna Vinschen <corinna@vinschen.de>
1333
1334 * fhandler_disk_file.cc (fhandler_disk_file::opendir): Check descriptor
1335 created by cygheap_fdnew constructor.
1336 * fhandler_virtual.cc (fhandler_virtual::opendir): Ditto.
1337 * fhandler_socket.cc (fhandler_socket::accept): Ditto and move
1338 creation of file descriptor behind blocking OS call.
1339 * net.cc (cygwin_socket): Ditto.
1340 (cygwin_rcmd): Ditto.
1341 (cygwin_rresvport): Ditto.
1342 (cygwin_rexec): Ditto.
1343 (socketpair): Ditto.
1344
3a88cf1b
CV
13452003-02-20 Corinna Vinschen <corinna@vinschen.de>
1346
1347 * autoload.cc (GetCompressedFileSize): Add.
1348 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Compute
1349 st_blocks value from GetCompressedFileSize() if available.
1350
79207923
CV
13512003-02-18 Vaclav Haisman <V.Haisman@sh.cvut.cz>
1352
1353 * wincap.h (wincaps::supports_sparse_files): New flag.
1354 (wincapc::supports_sparse_files): New method.
1355 * wincap.cc (wincap_unknown): Define value for the new flag.
1356 (wincap_95): Ditto.
1357 (wincap_95osr2): Ditto.
1358 (wincap_98): Ditto.
1359 (wincap_98se): Ditto.
1360 (wincap_me): Ditto.
1361 (wincap_nt3): Ditto.
1362 (wincap_nt4): Ditto.
1363 (wincap_nt4sp4): Ditto.
1364 (wincap_2000): Ditto.
1365 (wincap_xp): Ditto.
1366 * path.h (path_conv::fs_flags): New method.
005c3065
CF
1367 * fhandler_disk_file.cc: Include winioctl.h for DeviceIoControl.
1368 (fhandler_disk_file::open): Set newly created and truncated files as
79207923
CV
1369 sparse on platforms that support it.
1370
afe13e84
CV
13712003-02-17 Pierre Humblet <pierre.humblet@ieee.org>
1372
1373 * grp.cc (internal_getgroups): Handle properly tokens with
1374 no groups. Fix bug introduced on 2003-02-04.
1375
8fc16812
CF
13762003-02-16 Christopher Faylor <cgf@redhat.com>
1377
408e9b2f 1378 * cygwin.din: Export all appropriate newlib libm functions. Sort.
8fc16812
CF
1379 * include/cygwin/version.h: Bump API minor number.
1380
f655eadf
CF
13812003-02-15 Christopher Faylor <cgf@redhat.com>
1382
8fc16812 1383 * cygwin.din: Export all appropriate newlib libc functions.
f655eadf
CF
1384 * include/cygwin/version.h: Bump API minor number.
1385
4d9ba012
CV
13862003-02-14 Jason Tishler <jason@tishler.net>
1387
1388 * mmap.cc (mprotect): Add missing break.
1389
dff01e3a
CF
13902003-02-13 Christopher Faylor <cgf@redhat.com>
1391
1392 * exceptions.cc (try_to_debug): Don't reset priority when returning
1393 from non-waitloop call.
d1d1797e
CF
1394
13952003-02-13 Vaclav Haisman <V.Haisman@sh.cvut.cz>
005c3065 1396 Christopher Faylor <cgf@redhat.com>
d1d1797e
CF
1397
1398 * fhandler_console.cc (fhandler_console::write_normal): Use MessageBeep
1399 for bell sound.
1400 * autoload.cc (MessageBeep): Add.
1401
97c61aeb
CF
14022003-02-13 Christopher Faylor <cgf@redhat.com>
1403
1404 * include/cygwin/types.h: Use correct ifdef guard for u_ definitions.
1405
a200c081
CF
14062003-02-13 Christopher Faylor <cgf@redhat.com>
1407
1408 * environ.cc (environ_init): Use strechr.
1409
2858de3a
CF
14102003-02-13 Christopher Faylor <cgf@redhat.com>
1411
1412 * include/cygwin/in.h (sockaddr_in): Fix typo.
1413
75c8a70c
CF
14142003-02-12 Christopher Faylor <cgf@redhat.com>
1415
1416 * path.h (path_conv): Reorganize slightly.
1417
939d19b0
CF
14182003-02-12 Christopher Faylor <cgf@redhat.com>
1419
1420 * fhandler_tty.cc (process_input): Add sanity check to ensure that
1421 console typeahead is cleared on signal.
1422
7a44ba05
CF
14232003-02-12 Christopher Faylor <cgf@redhat.com>
1424
1425 * spawn.cc (linebuf::~linebuf): Resurrect commented out (for
1426 debugging?) code.
1427
407b8df6
CF
14282003-02-10 Ralf Habacker <ralf.habacker@freenet.de>
1429
1430 * include/cygwin/in.h (in_attr_t): Define new type.
1431 * include/arpa/inet.h (inet_addr): Change return type to in_addr_t.
1432 (inet_lnaof): Ditto.
1433 (inet_netof): Ditto.
1434 (inet_network): Ditto.
1435
14362003-02-10 Christopher Faylor <cgf@redhat.com>
1437
1438 * include/cygwin/types.h: Move many *_t typedefs here. Protect them
1439 with ifdefs.
1440 * fhandler_disk_file.cc (fhandler_disk_file::fstat): Change ntsec_atts to mode_t.
1441 * security.cc (get_attribute_from_acl): Accept mode_t attribute.
1442 (get_nt_attribute): Ditto.
1443 (get_file_attribute): Ditto.
1444 (get_nt_object_attribute): Ditto.
1445 (get_object_attribute): Ditto.
1446 * security.h: Reflect above changes.
1447 * syscalls.cc (chown_worker): Change attrib to mode_t.
1448
ad80bc42
CF
14492003-02-08 Christopher Faylor <cgf@redhat.com>
1450
67c64e3b 1451 * include/cygwin/version.h: Bump DLL minor number to 21.
ad80bc42
CF
1452
14532003-02-07 Christopher Faylor <cgf@redhat.com>
1454
1455 * malloc.cc (DEFAULT_MMAP_THRESHOLD): Bump down to 16MB thanks to below
1456 changes.
1457
4136fdb1
CV
14582003-02-07 Corinna Vinschen <corinna@vinschen.de>
1459
1460 * mmap.cc (mmap_record::alloc_map): De-inline. Add offset and length
1461 parameter. Only protect pages actually unused currently. Do job
1462 of map_map() when initializing a map.
1463 (mmap_record::map_map): Reduce functionality for the reuse case
1464 of private anonymous mapping.
1465 (mmap_record::fixup_map): Format change.
1466 (list::add_record): Add offset and length parameter to call
1467 mmap_record::alloc_map() correctly.
1468 (mmap64): Rename `l' variable to `map_list'. Accomodate above changes.
1469 (munmap): Rename `l' variable to `map_list'.
1470 (msync): Ditto.
1471 (fhandler_disk_file::mmap): Streamline code.
1472 (mprotect): Ditto.
1473 (fixup_mmaps_after_fork): Rename `l' variable to `map_list'.
1474
49b84ce4
CF
14752003-02-07 Vaclav Haisman <V.Haisman@sh.cvut.cz>
1476 Christopher Faylor <cgf@redhat.com>
1477
1478 * exceptions.cc (try_to_debug): Set priority of current thread rather
1479 than the main thread. Make busy waiting loop less busy. Restore
1480 priority when function returns.
1481
bc5b63ed
CF
14822003-02-07 Christopher Faylor <cgf@redhat.com>
1483
1484 * malloc.cc (DEFAULT_MMAP_THRESHOLD): Set high to avoid mmaps.
1485
14862003-02-07 Christopher Faylor <cgf@redhat.com>
1487
1488 * pipe.cc (fhandler_pipe::close): Avoid extraneous this->.
1489
1de8d164
CF
14902003-02-06 Christopher Faylor <cgf@redhat.com>
1491
1492 * heap.cc (heap_init): Remove debugging code.
1493
565e8015
CV
14942003-02-06 Pierre Humblet <pierre.humblet@ieee.org>
1495
1496 * security.h: Introduce names UNKNOWN_UID and UNKNOWN_GID and delete
1de8d164 1497 declaration of is_grp_member.
565e8015
CV
1498 * uinfo.cc (internal_getlogin): Use UNKNOWN_GID.
1499 * passwd.cc (pwdgrp::read_passwd): Use UNKNOWN_UID.
1500 * grp.cc (pwdgrp::read_group): Change group name to provide better
1501 feedback.
1502 (getgrgid): Use gid16togid32.
1503 * sec_helper.cc (is_grp_member): Delete.
1504
d238c1b4
CF
15052003-02-05 Christopher Faylor <cgf@redhat.com>
1506
1507 * path.cc: Change 'to_posix_p' to 'to_posix' throughout.
1508 (conv_path_list_buf_size): Accommodate relative paths.
1509
b7f52fe8
CF
15102003-02-05 Christopher Faylor <cgf@redhat.com>
1511
1512 * path.cc (etc::dir_changed): Fix debug printf.
1513
62cd433e
CV
15142003-02-05 Corinna Vinschen <corinna@vinschen.de>
1515
1516 * sec_acl.cc (setacl): Move all permission settings to beginning of
1517 loop. Set default rights to same values as in alloc_sd(). Set DELETE
1518 for owner and default owner only if S_IWOTH is given.
1519
15202003-02-05 Pierre Humblet <pierre.humblet@ieee.org>
1521
1522 * sec_acl.cc: Change all __aclent16_t to __aclent32_t except in
1523 wrapper function definitions. Replace call to the aclXYZ functions by
1524 calls aclXYZ32.
1525 (searchace): Change type of third argument to __uid32_t and use
1526 ILLEGAL_UID instead of -1;
1527 (setacl): Remove some initializations. Only give STANDARD_RIGHTS_WRITE
1528 for S_IWOTH. Replace -1 by ILLEGAL_UID.
1529 (getacl): Change type of owner_sid, group_sid and ace_sid to cygpsid.
1530 In last else clause, suppress second call to ace_sid.get_id and use
1531 TRUE in first call. Replace EqualSid by ==.
1532 (acl_access): Call internal_getgroups in USER and GROUP cases.
1533 (acecmp: Define static.
1534 (acl32): Create from 16 bit type.
1535 (facl32): Ditto.
1536 (lacl32): Ditto.
1537 (aclcheck32): Ditto.
1538 (aclsort32): Ditto.
1539 (acltomode32): Ditto.
1540 (aclfrommode32): Ditto.
1541 (acltopbits32): Ditto.
1542 (aclfrompbits32): Ditto.
1543 (acltotext32): Ditto.
1544 (aclfromtext32): Ditto, and use strechr.
1545 (acl16to32): Create.
1546 (acl): Make it a wrapper function.
1547 (facl): Ditto.
1548 (lacl): Ditto.
1549 (aclcheck): Ditto.
1550 (aclsort): Ditto.
1551 (acltomode): Ditto.
1552 (aclfrommode): Ditto.
1553 (acltopbits): Ditto.
1554 (aclfrompbits): Ditto.
1555 (acltotext): Ditto.
1556 (aclfromtext): Ditto.
1557 * security.cc (write_sd): Call set_process_privilege and check
1558 ownership.
1559 (alloc_sd): Remove call to set_process_privilege and the owner check.
1560
cadd065b
CF
15612003-02-05 Christopher Faylor <cgf@redhat.com>
1562
1563 * include/sys/cygwin.h: Use C-style comments.
1564
0c8455c3
CV
15652003-02-05 Pierre Humblet <pierre.humblet@ieee.org>
1566
1567 * sec_helper.cc (get_sids_info): New function.
1568 * security.cc (extract_nt_dom_user): Simplify with strechr.
1569 (get_user_groups): Initialize glen to MAX_SID_LEN.
1570 (get_user_local_groups): Ditto.
1571 (get_attribute_from_acl): Define ace_sid as cygpsid.
1572 (get_nt_attribute): Define owner_sid and group_sid as cygpsid.
1573 Call get_sids_info instead of cygsid.get_{u,g}id and is_grp_member.
1574 (get_nt_object_attribute): Ditto.
1575 (alloc_sd): Define ace_sid as cygpsid.
1576
5ae9331a
TP
15772003-02-04 Thomas Pfaff <tpfaff@gmx.net>
1578
1579 * syscalls.cc (struct system_cleanup_args): New struct.
1580 (system_cleanup): New function.
1581 (system): Use pthread_cleanup_push and _pop to save and restore
1582 signal handlers and sigprocmask.
1583
3dbafd87
CV
15842003-02-04 Corinna Vinschen <corinna@vinschen.de>
1585
1586 * path.cc (symlink): Create security attributes so that only the
1587 user can modify the symlink.
1588 * security.cc (set_security_attribute): Remove symlink special
1589 handling.
1590
0daf2561
CV
15912003-02-04 Pierre Humblet <pierre.humblet@ieee.org>
1592
1593 * grp.cc (internal_getgroups): Do not return without closing
1594 the process handle.
1595
4a21c2d5
CV
15962003-02-04 Pierre Humblet <pierre.humblet@ieee.org>
1597
1598 * security.h (class cygpsid): New class.
1599 (class cygsid): Use cygpsid as base. Remove members psid, get_id,
1600 get_uid, get_gid, string, debug_printf and the == and != operators.
1601 (cygsidlist::clear_supp): Only do work if setgroups has been called.
1602 * sec_helper.cc: Define sid_auth NO_COPY.
1603 (cygpsid::operator==): New operator.
1604 (cygpsid::get_id): New function.
1605 (cygpsid::string): New function.
1606 (cygsid::string): Delete.
1607 (cygsid::get_id): Delete.
1608 * pwdgrp.h: Change arguments of internal_getpwsid,
1609 internal_getgrsid and internal_getgroups to cygpsid.
1610 * passwd.cc (internal_getpwsid): Change argument from cygsid to cygpsid.
d238c1b4 1611 * grp.cc (internal_getgrsid): Ditto.
4a21c2d5
CV
1612 (internal_getgroups): Ditto.
1613
335556d5
CF
16142003-02-03 Christopher Faylor <cgf@redhat.com>
1615
1616 Eliminate most unneeded this-> pointers throughout.
1617
153e83c6
CV
16182003-02-03 Pierre Humblet <pierre.humblet@ieee.org>
1619
1620 * security.h: Add third argument to set_process_privilege.
1621 * autoload.cc: Add OpenThreadToken.
1622 * sec_helper.cc (set_process_privilege): Add and use use_thread
1623 argument.
1624 * security.cc (alloc_sd): Modify call to set_process_privilege.
1625 Remember the result in each process. If failed and file owner is not
1626 the user, fail.
1627
f0f3ea68
CV
16282003-02-03 Corinna Vinschen <corinna@vinschen.de>
1629
1630 * fhandler_socket.cc (fhandler_socket::recvfrom): Return buffer
1631 length and don't set errno in case of WSAEMSGSIZE error.
1632 (fhandler_socket::recvmsg): Ditto.
1633
6688a061
CF
16342003-02-01 Christopher Faylor <cgf@redhat.com>
1635
1636 * grp.cc (getgrent32): Only refresh group entries when at beginning.
1637 (internal_getgrsid): Only refresh if uninitialized.
1638 (internal_getgrent): Ditto.
1639 * passwd.cc (getpwent): Only refresh passwd entries when at beginning.
1640 (pwdgrp::read_passwd): linebuf *cannot* be NO_COPY.
1641 (internal_getpwsid): Only refresh if uninitialized.
1642 (getpass): No need to refresh passwd data here.
1643 * pwdgrp.h (refresh): Eliminate default.
1644
a5a93a62
CF
16452003-01-31 Christopher Faylor <cgf@redhat.com>
1646
1647 * dlfcn.cc (dlerror): Only report load errors once per error.
1648
b0a82a85
CF
16492003-01-31 Christopher Faylor <cgf@redhat.com>
1650
1651 * fhandler_serial.cc (fhandler_serial::open): Avoid extraneous setting
1652 of res.
1653
1654 * termios.cc (tcsetattr): Correctly record errno after tcsetattr call.
1655
16562003-01-31 Troy Curtiss <troyc@usa.net>
1657
1658 * fhandler_serial.cc (fhandler_serial::tcsetattr): Add error-checking
1659 so that if any Win32 SetComm*() calls fail, errno gets set to EINVAL
1660 and tcsetattr() returns -1. Catch invalid bitrates, mostly. If baud
1661 rate setting is B0, just drop DTR and leave Win32 DCB bitrate as-is
1662 since 0 is not a valid Win32 setting.
1663 (fhandler_serial::tcgetattr): If DTR is low, populate the bitrate as
1664 B0, otherwise get it from the DCB.
1665
949c3da1
CF
16662003-01-31 Christopher Faylor <cgf@redhat.com>
1667
1668 * passwd.cc (pwdgrp::read_passwd): linebuf *must* be static (from
1669 Pierre Humblet).
1670 * pwdgrp.h (pwdgrp::refresh): Avoid calling read function if we already
1671 have lock since that means we are in the process of reading the file.
1672
485d85bf
CF
16732003-01-31 Jason Tishler <jason@tishler.net>
1674
1675 * shared.cc (shared_info::heap_chunk_size): Use correct variable when
1676 reading HKLM.
1677
704ce461
CF
16782003-01-30 Christopher Faylor <cgf@redhat.com>
1679
1680 * fhandler_registry.cc (fhandler_registry::exists): Fix off-by-one
1681 error when inspecting path.
1682
ba6e1083
CF
16832003-01-29 Christopher Faylor <cgf@redhat.com>
1684
1685 * lib/getopt.c: Allow environment variable control of POSIXLY_INCORRECT
1686 behavior.
1687
16882003-01-28 Corinna Vinschen <corinna@vinschen.de>
01e3c897
CV
1689
1690 * fhandler_socket.cc (fhandler_socket::accept): On successful execution
1691 set connection state of returned socket to CONNECTED.
1692
dfb366da
CF
16932003-01-27 Christopher Faylor <cgf@redhat.com>
1694
1695 * passwd.cc (pwdgrp::parse_passwd): Be more unforgiving about
1696 non-numeric fields.
1697
03dba1de
CF
16982003-01-26 Christopher Faylor <cgf@redhat.com>
1699
1700 * uinfo.cc (pwdgrp::next_num): Remove check for NULL since it is no
1701 longer a valid return from next_str.
1702 (pwdgrp::add_line): Duh. Revert to use strchr.
1703
fea48988
CF
17042003-01-26 Christopher Faylor <cgf@redhat.com>
1705
ca6018a0 1706 * string.h (strechr): New function.
fea48988
CF
1707 * uinfo.cc (pwdgrp::next_str): Search only for input char in string.
1708 Return EOS on failure. Don't check for NULL since it shouldn't be
1709 possible.
1710 (pwdgrp::add_line): Revert to replacing '\n' in input line with '\0'.
1711 (pwdgrp::next_num): Pass explicit separator character to next_str.
1712 * grp.cc (pwdgrp::parse_group): Ditto.
1713 * passwd.cc (pwdgrp::parse_passwd): Ditto. Revamp test for garbage
1714 input.
1715 * pwdgrp.h (pwdgrp::next_str): Don't use default parameter.
1716
9a751621
CF
17172003-01-26 Christopher Faylor <cgf@redhat.com>
1718
1719 * uinfo.cc (pwdgrp::load): Regularize strace output. Add warning for
1720 CreateFile failure.
1721
c9133395
CF
17222003-01-26 Christopher Faylor <cgf@redhat.com>
1723
bdbd7fb6
CF
1724 * passwd.cc (pwdgrp::parse_passwd): Eliminate use of memset. The
1725 structure should always be completely filled out.
1726 * grp.cc (pwdgrp::parse_group): Ditto.
1727
17282003-01-26 Christopher Faylor <cgf@redhat.com>
1729
1730 * grp.cc (pwdgrp::parse_group): Fix off-by-one problem in allocating
c9133395 1731 gr_mem.
65037056
CF
1732
17332003-01-26 Christopher Faylor <cgf@redhat.com>
1734
1735 * include/sys/strace.h (paranoid_printf): Define as not being part of
1736 "all" output.
1737
17382003-01-25 Christopher Faylor <cgf@redhat.com>
1739
1740 * pwdgrp.h (pwdgrp::next_num): Rename from next_int. Returns
1741 true/false if parse operation succeeded.
1742 (pwdgrp::reparse): Remove.
1743 (pwdgrp::raw_ptr): New function. Returns pointer in line.
1744 (pwdgrp::next_num): New functions for parsing other than unsigned long.
1745 * grp.cc (pwdgrp::parse_group): Reinstate previous parsing behavior.
1746 Don't fill in fields with NULL and assign empty gr_mem to known pointer
1747 rather than doing a pointless calloc. Streamline gr_mem parsing.
1748 Don't increment curr_lines here.
1749 * passwd.cc (pwdgrp::parse_passwd): Use new behavior of next_num.
1750 Don't increment curr_lines here.
1751 * uinfo.cc (pwdgrp::next_str): Keep returning EOL if out of data.
1752 (pwdgrp::reparse): Remove.
1753 (pwdgrp::next_num): Rename from next_int. Return bool indicating
1754 success of parse, argument returns value parsed.
1755 (pwdgrp::add_line): Increment curr_lines here on successful parse.
1756 (pwdgrp::load): (from Pierre Humblet) Don't return status. Just report
1757 it here.
1758
a53ddfe6
CF
17592003-01-25 Christopher Faylor <cgf@redhat.com>
1760
1761 * pwdgrp.cc (pwdgrp::reparse): Declare.
1762 * uinfo.cc (pwdgrp::reparse): Define.
c9b99d0d 1763 * grp.cc (pwdgrp::parse_group): Use reparse.
a53ddfe6 1764
4f7e12dd
CV
17652003-01-25 Pierre Humblet <pierre.humblet@ieee.org>
1766
1767 * syscalls.cc (seteuid32): On Win95 get the pw entry. If it exists
1768 update the euid and call cygheap->user.set_name. Remove special
1769 handling of ILLEGAL_UID.
ba6e1083 1770 (setgid32): Add a debug_printf. On Win95, always set the egid.
4f7e12dd
CV
1771 Remove special handling of ILLEGAL_GID. Do not compare gid and gr_gid.
1772 * child_info.h (class cygheap_exec_info): Remove uid.
1773 * spawn.cc (spawn_guts): Do not set ciresrv.moreinfo->uid.
1774 * dcrto.cc (dll_crt0_1): Always call uinfo_init.
1775 * uinfo.cc (uinfo_init): Reorganize and close handle if needed.
1776 (cygheap_user::ontherange): Do not call internal_getpwnam if pw is NULL.
1777
45dbfc26
CF
17782003-01-24 Christopher Faylor <cgf@redhat.com>
1779
1780 * fhandler_console.cc (fhandler_console::send_winch_maybe): Reset
1781 scroll region if size changes.
1782
7d33eefa
CV
17832003-01-24 Pierre Humblet <pierre.humblet@ieee.org>
1784 Jason Tishler <jason@tishler.net>
1785
1786 * cygwin.din: Export setreuid32, setreuid, setregid32, setregid.
1787 * syscalls.cc (setreuid32): New function.
1788 (setreuid): Ditto.
1789 (setregid32): Ditto.
1790 (setregid): Ditto.
1791 * include/cygwin/version.h: Bump API minor number.
1792
ac413374 17932003-01-23 Christopher Faylor <cgf@redhat.com>
69fae986 1794
ac413374 1795 * pwdrp.h (pwdgrp::refresh): Lock entire test prior to reading.
2037688a 1796
ac413374 17972003-01-23 Christopher Faylor <cgf@redhat.com>
09a88426
CF
1798
1799 * grp.cc (pwdgrp::parse_group): Eliminate arg and use class member
1800 instead. Use next_str and next_int to parse arguments.
1801 * passwd.cc (pwdgrp::parse_passwd): Ditto.
1802 (grab_string): Eliminate.
1803 (grab_int): Ditto.
1804 * pwdgrp.h (pwdgrp::parse): Eliminate input arg.
1805 (pwdgrp::parse_passwd): Reflect above change.
1806 (pwdgrp::parse_group): Reflect above change.
1807 (pwdgrp::next_str): New function.
1808 (pwdgrp::next_int): Ditto.
1809 (pwdgrp::gets): Eliminate.
1810 * uinfo.cc (pwdgrp::next_str): New function.
1811 (pwdgrp::next_int): Ditto.
1812 (pwdgrp::add_line): Subsume gets.
1813 (pwdgrp::gets): Eliminate.
1814 (pwdgrp::load): Just call add_line to parse input buffer.
1815
ac413374
CF
18162003-01-22 Thomas Pfaff <tpfaff@gmx.net>
1817
1818 * include/pthread.h (PTHREAD_MUTEX_RECURSIVE): Revert changes from
1819 2003-01-09 mutex patch.
1820 (PTHREAD_MUTEX_ERRORCHECK): Ditto.
1821
18222003-01-22 Corinna Vinschen <corinna@vinschen.de>
1823
1824 * cygrun.c: Move from here to ../testsuite.
1825 * Makefile.in: Remove cygrun.exe dependencies.
1826
18272003-01-21 Jason Tishler <jason@tishler.net>
1828
1829 * cygwin.din: Export nanosleep().
1830 * signal.cc (nanosleep): New function.
1831 (sleep): Move old functionality to nanosleep(). Call nanosleep().
1832 (usleep): Remove old functionality. Call nanosleep().
1833 * include/cygwin/version.h: Bump API minor number.
1834
57394495
CF
18352003-01-21 Christopher Faylor <cgf@redhat.com>
1836
1837 * grp.cc: Call gr.refresh() rather than doing isunitialized tests
1838 throughout.
1839 (gr): Use constructor (sigh).
1840 (pwdgrp::parse_group): Rename from parse_grp.
1841 (pwdgrp::read_group): Rename from read_etc_group. Just call gr.load
1842 with a single argument.
1843 * passwd.cc: Call pr.refresh() rather than doing isunitialized tests
1844 throughout.
1845 (pr): Use constructor (sigh).
1846 (pwdgrp::parse_passwd): Rename from "parse_pwd".
1847 (pwdgrp::read_passwd): Rename from read_etc_passwd. Just call pr.load
1848 with a single argument.
1849 * pwdgrp.h (pwdgrp_state): Eliminate.
1850 (pwdgrp): Reflect above renamings.
1851 (pwdgrp::etc_ix): Rename from pwd_ix.
1852 (pwdgrp::read): New element.
1853 (pwdgrp::lock): New element.
1854 (pwdgrp::refresh): New function.
1855 (pwdgrp::load): Eliminate variations which take buffer arguments.
1856 (pwdgrp::pwdgrp): New constructors. Initialize mutex here.
1857 * uinfo.cc (pwdgrp::load): Accommodate pwd_ix -> etc_ix renaming.
1858 (pwdgrp::load): Set initialized state to true rather than setting state
1859 to loaded.
1860
984864e9
CF
18612003-01-21 Christopher Faylor <cgf@redhat.com>
1862
89f7e8d1 1863 * include/cygwin/version.h: Bump DLL minor number.
984864e9 1864
d8cde3a3
CF
18652003-01-21 Pierre Humblet <pierre.humblet@ieee.org>
1866
1867 * path.h (etc::change_possible): Revert the type to bool.
1868 (etc::set_last_modified): Remove obsolete function.
1869 * path.cc (etc::change_possible): Revert type to bool.
1870 (etc::test_file_change): Do not test for negative values of
1871 change_possible and do not set it to -res.
1872 (etc::dir_changed): When the handle is NULL, call memset instead of
09a88426
CF
1873 test_file_changed. When the handle is invalid, return true. Detect
1874 filename change in /etc.
d8cde3a3 1875 (etc::file_changed): Remove unneeded check for !fn[n].
33de631b 1876 * uinfo.cc (pwdgrp::load): Eliminate spurious setting of fh to NULL.
b99b804b 1877 * pwdgrp.h (pwdgrp::operator =): Eliminate.
d8cde3a3 1878
7905c4f1
CF
18792003-01-19 Christopher Faylor <cgf@redhat.com>
1880
1881 * pwdgrp.h (etc): Move to path.h.
1882 (pwdgrp::max_lines): New field.
1883 (pwdgrp::curr_lines): New field.
1884 (pwdgrp::pwdgrp_buf): Ditto.
1885 (pwdgrp_buf_elem_size): Ditto.
1886 (pwdgrp_parse): Ditto.
1887 (pwdgrp::gets): Just declare here.
1888 (pwdgrp::load): Ditto. Just take one argument.
1889 (pwdgrp::load): Define overloaded function accepting passwd buf.
1890 (pwdgrp::load): Define overloaded function accepting group buf.
1891 * grp.cc: Use pwdgrp elements rather than standalone static variables
1892 throughout.
1893 (curr_lines): Eliminate.
1894 (max_lines): Ditto.
1895 (add_grp_line): Ditto.
1896 (parse_grp): Define as returning boolean. Accept void * arg and line
1897 count. Coerce first argument into __group32 buf reference. Increment
1898 curr_line as appropriate.
1899 (read_etc_group): Pass pwdgrp buffer to gr.load.
1900 * passwd.cc: Use pwdgrp elements rather than standalone static variables
1901 throughout.
1902 (curr_lines): Eliminate.
1903 (max_lines): Ditto.
1904 (add_grp_line): Ditto.
1905 (parse_passwd): Define as returning boolean. Accept void * arg and line
1906 count. Coerce first argument into passwd buf reference. Increment
1907 curr_line as appropriate.
1908 (read_etc_group): Pass pwdgrp buffer to pr.load.
1909 * path.cc (etc::fn): Extend buffer size to allow index by 1 rather than
1910 zero.
1911 (etc::last_modified): Ditto.
1912 (etc::change_possible): Ditto. Renamed from sawchange. Change to
1913 signed char since elements are now tri-state.
1914 (etc::init): Assume "handle" is 1 based rather than 0.
1915 (etc::test_file_change): New function. Sets change_possible based on
1916 file date comparison.
1917 (etc::dir_changed): Check file states immediately after changed_h is
1918 initialized to avoid a race.
1919 (etc::file_changed): Use test_file_change to detect if file needs to be
1920 updated.
1921 * path.h (etc): Move class here from pwdgrp.h.
7905c4f1
CF
1922 * uinfo.cc: Move etc:: functions to path.cc. Move pwdgrp functions
1923 here.
1924 (pwdgrp::gets): Eliminate buf checks. Just check eptr and set lptr.
1925 (pwdgrp::add_line): New function.
1926 (pwdgrp::load): Call generic add_line function which will call correct
1927 parser.
1928
4c6a3e50
CF
19292003-01-17 Christopher Faylor <cgf@redhat.com>
1930
1931 * cygheap.cc: Change most 'int's to 'unsigned's.
1932 (_cmalloc): Only check for size of malloced region when calculating
97d2bc79 1933 bucket. Add overhead when performing the sbrk. Previous change broke
4c6a3e50
CF
1934 _crealloc.
1935
e9152439
CF
19362003-01-17 Christopher Faylor <cgf@redhat.com>
1937
1938 * dcrt0.cc (initialize_env): Use colon for CYGWIN_DEBUG separator.
1939 * grp.cc: Change most statics to NO_COPY throughout.
1940 * passwd.cc: Ditto.
1941
19422003-01-17 Christopher Faylor <cgf@redhat.com>
1943
1944 * pwdgrp.h: Change some BOOLs to bools.
1945 (pwdgrp::pwdgrp): Remove unneeded constructor.
1946 * passwd.cc: Change BOOL to bool throughout.
1947
afa378e7
CV
19482003-01-17 Corinna Vinschen <corinna@vinschen.de>
1949
1950 * cygwin.din: Add strerror_r.
1951 * include/cygwin/version.h: Bump API minor number.
1952
1de6f431
CF
19532003-01-17 Christopher Faylor <cgf@redhat.com>
1954
1955 * uinfo.cc (etc::dir_changed): Don't print a warning if can't open
1956 /etc, unless debugging.
1957
d8cde3a3 19582003-01-17 Pierre Humblet <pierre.humblet@ieee.org>
14ea5029
CF
1959
1960 * grp.cc (read_etc_group): On NT, add a line for gid = -1. Change name
1961 "unknown" to "mkgroup".
1962 (internal_getgrgid): Do not return default in nontsec case.
1963 (internal_getgroups): Add argument srchsid and look for it in groups if
1964 not NULL.
1965 * passwd.cc (read_etc_passwd): On NT, add a line for uid = -1. Use
1966 same default uid for Win95 and NT. Call cygheap_user::ontherange to
1967 initialize HOME.
1968
14ea5029
CF
19692003-01-16 Christopher Faylor <cgf@redhat.com>
1970
1971 * cygheap.cc (init_cygheap::etc_changed): Move to uinfo.cc.
1972 * cygheap.h (init_cygheap::etc_changed_h): Remove.
1973 (init_cygheap::etc_changed): Ditto.
1974 * grp.cc (group_state): Remove. Use gr instead throughout.
1975 (gr): Define as class pwdgrp.
1976 (read_etc_group): Remove gr definition. Remove calls to
1977 set_last_modified and close. Pass add_grp to gr.load to load file.
1978 * passwd.cc (passwd_state): Remove. Use pr instead, throughout.
1979 (pr): Define as class pwdgrp.
1980 (read_etc_passwd): Remove pr definition. Remove calls to
1981 set_last_modified and close. Pass add_pwd_line to pr.load to load
1982 file.
1983 * pwdgrp.h (etc): New helper class for pwdgrp.
1984 (pwdgrp): Combine pwdgrp_check and pwdgrp_read into one class. Remove
1985 file_w32 and last_modified fields.
1986 (pwdgrp::set_last_modified): Remove.
1987 (pwdgrp::isinitializing): Remove FindFirstFile stuff. Move to
1988 etc::file_changed.
1989 (pwdgrp::load): Rename from 'open'. Call etc::init to initialize etc
1990 scanning. Close file handle after reading buffer into memory. Parse
1991 buffer by calling second argument.
1992 (pwdgrp::gets): Reorganize slightly to rely on eptr starting at
5304bcdf 1993 beginning of buffer.
14ea5029
CF
1994 (pwdgrp::close): Remove.
1995 * uinfo.cc (etc::dir_changed): New function.
1996 (etc::init): Ditto.
1997 (etc::file_changed): Ditto.
1998 (etc::set_last_modified): Ditto.
1999
41429bc9
CV
20002003-01-16 Jason Tishler <jason@tishler.net>
2001
2002 * mmap.cc (fixup_mmaps_after_fork): Add ERROR_NOACCESS to the list of
2003 ReadProcessMemory() error codes that trigger a retry with temporary
2004 PAGE_READONLY access. Note that this can occur on NT 4.0.
2005
18813254
CF
20062003-01-15 Christopher Faylor <cgf@redhat.com>
2007
2008 * path.cc (normalize_posix_path): Convert win32 path separators to
2009 slashes when full path is specified.
2010
77cb0c56
CF
20112003-01-15 Pierre Humblet <pierre.humblet@ieee.org>
2012
2013 * cmalloc.cc (_cmalloc): Fix memory leak.
2014
ce542f78
CV
20152003-01-15 Corinna Vinschen <corinna@vinschen.de>
2016
2017 * autoload.cc: Fix copyright date.
2018 * fhandler_dsp.cc: Ditto.
2019 * mmap.cc: Ditto.
2020 * net.cc: Ditto.
2021 * ntdll.h: Ditto.
2022 * signal.cc: Ditto.
2023 * syscalls.cc: Ditto.
2024 * uname.cc: Ditto.
2025 * wait.cc: Ditto.
2026
15996b6f
CV
20272003-01-14 Corinna Vinschen <corinna@vinschen.de>
2028
2029 * mmap.cc (fixup_mmaps_after_fork): Copy protection to child process.
2030 Change ambiguous debug output.
2031
857b65dd
CV
20322003-01-14 Corinna Vinschen <corinna@vinschen.de>
2033
2034 * mmap.cc (mmap_record::access): Change argument type to caddr_t
2035 for strictness.
2036 (mprotect): Protect against calling VirtualProtect() for shared
2037 pages on 9x/Me.
2038 (fixup_mmaps_after_fork): If ReadProcessMemory() fails, try to
2039 change protection of parent page to PAGE_READONLY, then try again.
2040 Revert protection afterwards.
2041
e14328f4
TP
20422003-01-14 Thomas Pfaff <tpfaff@gmx.net>
2043
2044 * syscalls.cc (system): Add pthread_testcancel call.
2045 * thread.cc: Update list of cancellation points.
2046
4a3584c8
TP
20472003-01-14 Thomas Pfaff <tpfaff@gmx.net>
2048
2049 * wait.cc: Include thread.h
2050 (wait4): Add pthread_testcancel call.
2051 Wait for child process and cancellation event.
2052 * thread.cc: Update list of cancellation points.
2053
7ec66a2c
TP
20542003-01-14 Thomas Pfaff <tpfaff@gmx.net>
2055
2056 * signal.cc (sleep): Add pthread_testcancel call.
2057 Wait for signal and cancellation event.
2058 (usleep): Ditto.
2059
20602003-01-14 Thomas Pfaff <tpfaff@gmx.net>
3457ce4d
TP
2061
2062 * exceptions.cc (handle_sigsuspend): Add pthread_testcancel call.
2063 Wait for signal and cancellation event.
2064 * thread.cc: Update list of cancellation points.
2065
2673d5f2
CF
20662003-01-14 David Huang <davehzhr@hotmail.com>
2067
2068 * fhandler_dsp.cc (fhandler_dsp::ioctl): Add limited support for
2069 SNDCTL_DSP_GETFMTS.
2070
9f0d3f37
CF
20712003-01-12 Christopher Faylor <cgf@redhat.com>
2072
2073 * ntdll.h: Fix typo.
2074
7f129d87
CV
20752003-01-12 Corinna Vinschen <corinna@vinschen.de>
2076
2077 * uname.cc (uname): Use cygwin_gethostname() to retrieve hostname.
2078
ab2dbccc
CV
20792003-01-12 Pierre Humblet <pierre.humblet@ieee.org>
2080
2081 * sec_acl.cc (search_ace): Use id == -1, instead of < 0, as wildcard.
2082 (setacl): Start the search for a matching default at the next entry.
2083 Invalidate the type of merged entries instead of clearing it.
2084 Use well_known_creator for default owner and owning group and do
2085 not try to merge non-default and default entries in these cases.
2086 (getacl): Recognize well_known_creator for default owner and group.
2087 (acl_worker): Improve errno settings and streamline the nontsec case.
2088 * security.cc (write_sd): Remove the call to set_process_privilege.
2089 (alloc_sd): If the owner changes, call set_process_privilege and return
2090 immediately on failure. Change inheritance rules: on new directories add
2091 inherit only allow ACEs for creator_owner, creator_group and everyone.
2092 Preserve all inheritances through chmod and chown calls. Introduce
2093 isownergroup to implement the uid == gid case, to keep the inheritance
2094 code simple. Do not initialize owner_sid and group_sid and stop using
2095 the variable psd.
2096
68115c74
CF
20972003-01-10 Christopher Faylor <cgf@redhat.com>
2098
2099 * net.cc: Use gethostname define from winsock2.h.
2100
e3abf986
CF
21012003-01-10 Christopher Faylor <cgf@redhat.com>
2102
2103 * path.cc: Unrevert below reversion except for
2104 mount_info::conv_to_posix_path part.
2105
df2caa88
CV
21062003-01-10 Corinna Vinschen <corinna@vinschen.de>
2107
2108 * path.cc: Revert patch from 2003-01-09 to normalize a windows path
2109 rather than converting to posix.
2110
dc8d11f5
CV
21112003-01-10 Corinna Vinschen <corinna@vinschen.de>
2112
2113 * autoload.cc (gethostname): Make call optional, return 1 if function
2114 can't get loaded.
2115 * net.cc (cygwin_gethostname): Call GetComputerName if return value
2116 of gethostname is non-zero.
2117
70d61f30
CV
21182003-01-10 Charles Wilson <cwilson@ece.gatech.edu>
2119
8735f49f 2120 * cygwin.din: Add asprintf and vasprintf, as well as the reentrant
70d61f30 2121 versions and underscore variants.
8735f49f 2122 * include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR.
70d61f30 2123
a7711767
CV
21242003-01-10 Corinna Vinschen <corinna@vinschen.de>
2125
2126 * net.cc (cygwin_gethostname): Fix call to wsock function gethostname.
2127
d5223b2b
CF
21282003-01-09 Christopher Faylor <cgf@redhat.com>
2129
2130 * cygthread.cc (cygthread::cygthread): Be more noisy about odd
2131 condition.
2132 * miscfuncs.cc (low_priority_sleep): Sleep in regular priority if
2133 that's what we're currently running at.
2134
65f207e8
TP
21352003-01-09 Thomas Pfaff <tpfaff@gmx.net>
2136
2137 * include/semaphore.h: Modify typedef for sem_t.
2138 * include/cygwin/types.h: Modify typedefs for pthread_t,
2139 pthread_mutex_t, pthread_key_t, pthread_attr_t,
2140 pthread_mutexattr_t, pthread_condattr_t, pthread_cond_t,
2141 pthread_rwlock_t and pthread_rwlockattr_t.
2142
09cbb9d6
TP
21432003-01-09 Thomas Pfaff <tpfaff@gmx.net>
2144
2145 * thread.h (WAIT_CANCELED): New define.
2146 (pthread::cancelable_wait): New static method.
2147 * thread.cc (pthread::cancelable_wait): Implement.
2148 (semaphore::Wait): Wait on semaphore and thread cancellation.
2149 (pthread::join): Wait on joined thread and thread cancellation.
2150 (semaphore::wait): Add testcancel to check for thread
2151 cancellation even if the semaphore is available.
2152
5d68d1de
TP
21532003-01-09 Thomas Pfaff <tpfaff@gmx.net>
2154
2155 * include/pthread.h: Add define for errorchecking mutexes.
2156 Change default mutex type.
2157 * thread.cc (pthread_cond::TimedWait): Update mutex unlock
2158 calls.
2159 (pthread_mutex::pthread_mutex): New implement.
2160 (pthread_mutex::~pthread_mutex): Ditto.
2161 (pthread_mutex::Lock): Ditto.
2162 (pthread_mutex::TryLock): Ditto.
2163 (pthread_mutex::UnLock): Ditto.
2164 (pthread_mutex::Destroy): Implement new method.
2165 (pthread_mutex::SetOwner): Ditto.
2166 (pthread_mutex::LockRecursive): Ditto.
2167 (pthread_mutex::fixup_after_fork): Restore locking state after
2168 fork.
2169 (__pthread_mutex_lock): Return pthread_mutex::Lock errorcode.
2170 (__pthread_mutex_trylock): Return pthread_mutex::TryLock
2171 errorcode.
2172 (__pthread_mutex_unlock): Return pthread_mutex::UnLock
2173 errorcode.
2174 (__pthread_mutex_destroy): Call pthread_mutex::Destroy to
3457ce4d 2175 destroy mutex.
5d68d1de
TP
2176 (__pthread_mutexattr_settype): Allow errorchecking and recursive
2177 types.
2178 * thread.h (MUTEX_LOCK_COUNTER_INITIAL): New define.
2179 (pthread_mutex::criticalsection): Remove.
2180 (pthread_mutex::lock_counter): New member.
2181 (pthread_mutex::recursion_counter): Ditto.
2182 (pthread_mutex::owner): Ditto.
2183 (pthread_mutex::type): Ditto.
2184 (pthread_mutex::Destroy): New method.
2185 (pthread_mutex::SetOwner): Ditto.
2186 (pthread_mutex::LockRecursive): Ditto.
2187
ed9fe455
TP
21882003-01-09 Thomas Pfaff <tpfaff@gmx.net>
2189
2190 * pthread.cc (pthread_cond_init): Use new pthread_cond::init.
2191 * thread.cc: Some white spaces cleanups.
2192 Change __pthread_cond_init to pthread_cond::init throughout.
2193 (nativeMutex): Move class methods outside pthread_mutex.
2194 (MTinterface::Init): Initialize pthread_cond init lock.
2195 (pthread_cond::condInitializationLock): Instantiate.
2196 (pthread_cond::initMutex): New Method.
2197 (pthread_cond::isGoodInitializerOrBadObject): Ditto.
2198 * thread.h: Some white spaces cleanups.
2199 (nativeMutex): Move class declaration outside pthread_mutex.
2200 (pthread_cond::condInitializationLock): New static member.
2201 (pthread_cond::initMutex): New Method.
2202 (pthread_cond::isGoodInitializerOrBadObject): Ditto.
2203 (__pthread_cond_init): Remove prototype.
2204
93353aee
CV
22052003-01-09 Corinna Vinschen <corinna@vinschen.de>
2206
2207 * fhandler_disk_file.cc (num_entries): Return 2 as link count if
2208 directory unreadable.
2209
3eb27a4e
CV
22102003-01-09 Corinna Vinschen <corinna@vinschen.de>
2211
2212 * security.cc (get_nt_attribute): Always return -1 when read_sd()
2213 fails.
2214 (get_file_attribute): Set permissions to 0 and owner/group to -1
2215 if security descriptor is unreadable.
2216
85ba109d
CF
22172003-01-09 Christopher Faylor <cgf@redhat.com>
2218
2219 Use isdirsep rather than SLASH_P throughout.
2220 * path.cc (iscygdrive): Disallow /cygdrive\x.
2221 (normalize_posix_path): "Normalize" a windows path, if detected, rather
2222 than converting to posix.
2223
22242003-01-06 Troy Curtiss <troyc@usa.net>
2225
2226 * fhandler_serial.cc (fhandler_serial::tcsetattr): Add support and
2227 capability checking for B230400 bitrate.
2228 (fhandler_serial::tcgetattr): Add support for B230400 bitrate.
2229 * include/sys/termios.h: Add B230400 definition for Posix support of
2230 230.4Kbps.
2231
cbdbe9d7
CF
22322003-01-05 Christopher Faylor <cgf@redhat.com>
2233
2234 * pinfo.cc (_pinfo::commune_send): Use myself->lock rather than just
2235 lock when leaving.
2236
f3afe99b
CF
22372003-01-03 Christopher Faylor <cgf@redhat.com>
2238
2239 * dtable.h (dtable::in_vfork_cleanup): New function. True if vfork
2240 cleanup needed.
2241 * dtable.cc (dtable::vfork_parent_restore): Remove assertion.
2242 * pipe.cc (fhandler_pipe::close): Don't close read_state during
2243 fork_fixup since it wasn't inherited.
2244
2665fb15
CF
22452003-01-01 Christopher Faylor <cgf@redhat.com>
2246
2247 * passwd.cc (getpwuid_r32): Revert previous change.
2248
8619b42b
CF
22492003-01-01 Christopher Faylor <cgf@redhat.com>
2250
2251 * sysconf.cc (sysconf): Return arbitrary values for
2252 _SC_GETGR_R_SIZE_MAX, _SC_LOGIN_NAME_MAX, _SC_GETPW_R_SIZE_MAX.
2253
2254 * passwd.cc (getpwuid_r32): Add uid/gid fields to size check
2255 calculation.
2256
This page took 0.304069 seconds and 5 git commands to generate.