]> sourceware.org Git - newlib-cygwin.git/blame - winsup/cygwin/ChangeLog
Sun Apr 22 20:22:00 2001 Robert Collins <rbtcollins@hotmail.com>
[newlib-cygwin.git] / winsup / cygwin / ChangeLog
CommitLineData
9450ad0d
RC
1Sun Apr 22 00:22:00 2001 Robert Collins <rbtcollins@hotmail.com>
2
3 * passwd.cc (getpwuid): Check for thread cancellation.
4 (getpwuid_r): Ditto.
5 (getpwname): Ditto.
6 (getpwnam_r): Ditto.
7 * thread.h (pthread_mutex): New constructors for pshared operation.
8 (MTinterface): Associative array for pshared mutex's.
9 * thread.cc (MTinterface::Init): Initailize pshared mutex array.
10 (pthread_cond::BroadCast): Implementation notes.
11 (pthread_cond::TimedWait): Remove use of SignalObjectAndWait on non-NT systems.
12 (pthread_mutex::pthread_mutex(unsigned short)): New function.
13 (pthread_mutex::pthread_mutex (pthread_mutex_t *, pthread_mutexattr *)):New function.
14 (pthread_mutex::pthread_mutex(pthread_mutexattr *)): Fail on pshared mutex's.
15 (__pthread_mutex_getpshared): New function.
16 (__pthread_join): Check for thread cancellation.
17 (__pthread_cond_timedwait): Support pshared mutex's.
18 (__pthread_cond_wait): Ditto.
19 (__pthread_condattr_setpshared): Error on PROCESS_SHARED requests.
20 (__pthread_mutex_init): Support pshared mutex's.
21 (__pthread_mutex_getprioceiling): Ditto.
22 (__pthread_mutex_lock): Ditto.
23 (__pthread_mutex_trylock): Ditto.
24 (__pthread_mutex_unlock): Ditto.
25 (__pthread_mutex_destroy): Ditto.
26 (__pthread_mutex_setprioceiling): Ditto.
27 (__pthread_mutexattr_setpshared): Support PTHREAD_PROCESS_PSHARED requests.
28
60326076
CF
29Fri Apr 20 19:38:29 2001 Christopher Faylor <cgf@cygnus.com>
30
31 * cygwin.din: Add *scanf and *scan_r functions.
32
3c8e92d9
CV
33Fri Apr 20 22:25:00 2001 Corinna Vinschen <corinna@vinschen.de>
34
35 * security.cc (set_process_privileges): Swap out.
36 * sec_helper.cc (set_process_privilege): Rename from
37 `set_process_privileges'. Takes the privilege to enable or disable
38 as parameter now.
39 * security.h: Add prototype for `set_process_privileges'.
40
b9815dc3
CF
412001-04-19 Egor Duda <deo@logos-m.ru>
42
43 * path.cc (path_conv::check): Always initialize member variables.
44
cbd88687
CF
45Fri Apr 20 12:27:49 2001 Christopher Faylor <cgf@cygnus.com>
46
47 * include/sys/file.h: More cleanup for X_OK.
48
cdcfe4e8
CF
49Fri Apr 20 11:48:45 2001 Christopher Faylor <cgf@cygnus.com>
50
51 * include/sys/file.h: Move X_OK protection earlier.
52
53 * dtable.cc (dtable::vfork_child_fixup): Avoid closing already closed
54 handles.
55
bfbc1aec
CV
56Fri Apr 20 16:29:00 2001 Corinna Vinschen <corinna@vinschen.de>
57
58 * grp.cc (getgroups): Change so that SIDs get compared instead
59 of strings to SIDs.
60
c0d1968a
CV
61Fri Apr 20 14:50:00 2001 Corinna Vinschen <corinna@vinschen.de>
62
63 * Makefile.in: Add object files `sec_helper.cc' and `sec_acl.cc'.
64 * security.cc: Swap out several functions.
65 * sec_acl.cc: New file. Move Sun compatibel ACL functions from
66 `security.cc' to here.
67 * sec_helper.cc: New file. Move security helper functions from
68 `security.cc' to here.
69 * security.h: Changed to accomodate the above changes.
70
71Fri Apr 20 14:12:00 2001 Corinna Vinschen <corinna@vinschen.de>
72
73 * grp.cc: Replace `group_in_memory_p' by `group_state'.
74 Eliminate group_sem throughout.
75 (enum grp_state): New enumeration type.
76 (read_etc_group): Make race safe.
77 * security.cc: Eliminate group_sem throughout.
78
b78d6f6e
CV
79Thu Apr 19 9:40:00 2001 Corinna Vinschen <corinna@vinschen.de>
80
81 * mmap.cc (mmap): Drop usage of the same memory area if the same
82 region of the same file is mapped twice.
83
0381fec6
CF
84Wed Apr 18 16:53:54 2001 Christopher Faylor <cgf@cygnus.com>
85
86 Throughout, change fdtab references to cygheap->fdtab.
87 * child_info.h (cygheap_exec_info): Eliminate special fdtab stuff.
88 * spawn.cc (spawn_guts): Ditto.
89 * cygheap.cc (cygheap_init): Initialize fdtab, if appropriate.
90 * cygheap.h (CYGHEAPSIZE): Include size of init_cygheap.
91 (_cmalloc_entry): Include fdtab here.
92 * dtable.h (dtable): Declare/define new methods.
93 * dtable.cc (dtable::vfork_child_fixup): New method.
94 (dtable::fixup_after_exec): Remove unneeded extra arguments.
95 * dcrt0.cc (dll_crt0_1): Ditto.
96
97 * environ.cc (getwinenv): Use case sensitive comparison.
98 (winenv): Make a copy of environment cache to avoid realloc problems
99 when duplicate environment variables exist in the environment. (From
100 Egor Duda)
101
102 * net.cc (cygwin_socket): Revert Apr 14 change.
103
104 * include/sys/file.h: Protect against previous X_OK definition.
105
106Tue Apr 17 12:18:28 2001 Christopher Faylor <cgf@cygnus.com>
107
108 * passwd.cc: Eliminate passwd_sem throughout.
109 * security.cc: Ditto.
110
111Tue Apr 17 12:18:28 2001 Robert Collins <rbtcollins@hotmail.com>
112
113 * cygwin.din: Export New functions.
114 * passwd.cc (read_etc_passwd): Make race safe.
115 (getpwuid_r): New function.
116 (getpwnam_r): New function.
117
77c45b12
CV
1182001-04-18 Egor Duda <deo@logos-m.ru>
119
120 * grp.cc (getgroups): Avoid crash if passwd field if /etc/group is
121 empty.
122
4199e1e6
CF
123Tue Apr 17 19:05:44 2001 Christopher Faylor <cgf@cygnus.com>
124
125 * path.h (path_conv::add_ext_from_sym): Declare.
126 * path.cc (path_conv::add_ext_from_sym): Convert to pure inline method.
127
e6629a8a
CV
128Tue Apr 17 18:50:00 2001 Corinna Vinschen <corinna@vinschen.de>
129
130 * path.cc (windows_device_names): Add missing NULL element.
131
adfd477d
CF
132Tue Apr 17 12:14:54 2001 Christopher Faylor <cgf@cygnus.com>
133
134 * path.cc (windows_device_names): Move dsp to proper location.
135
8aefe7c0
CV
136Tue Apr 17 13:44:00 2001 Corinna Vinschen <corinna@vinschen.de>
137
138 * path.cc (path_conv::check): Set case_clash even if pcheck_case
139 is set to PCHECK_ADJUST when a case clash is given for the last
140 component in path.
141 (symlink_info::case_check): Ditto.
142 * syscalls.cc (_rename): Avoid overwriting an already existing file
143 if a case clash is given even if pcheck_case is set to PCHECK_ADJUST.
144
77eb506d
CV
145Tue Apr 17 2:07:07 2001 Christopher Faylor <cgf@cygnus.com>
146
147 * config.h.in: Turn off VFORK again.
148
431ba7dd
CF
149Mon Apr 16 23:45:24 2001 Christopher Faylor <cgf@cygnus.com>
150
151 * path.h (cwdstuff): Move class.
152 * cygheap.h (cwdstuff): To here.
153 (init_cygheap): Add cwd field.
154 * child_info.h (cygheap_exec_info): Eliminate cwd stuff.
155 (child_info_spawn): Ditto.
156 * dcrt0.cc (dll_crt0_1): Remove cygcwd.fixup_after_exec call. Convert
157 cygcwd reference to cygheap->cwd.
158 * path.cc: Ditto, throughout.
159 (cwdstuff::copy): Eliminate.
160 (cwdstuff::fixup_after_exec): Ditto.
161 * spawn.cc (spawn_guts): Eliminate call to cygcwd.copy.
162
163 * fhandler.h (FH_OSS_DSP): Move into "fast" device category.
164
7ade56ca
CV
165Mon Apr 16 19:19:00 2001 Corinna Vinschen <corinna@vinschen.de>
166
167 * mmap.cc: Move fh_paging_file from some functions to be
168 a global static variable.
169 (class mmap_record): Add `devtype_' member to remember
170 the device type of the file. Add declaration for methods
171 `get_device', `alloc_fh' and `free_fh'.
172 (mmap_record::mmap_record): Initialize `devtype_' correctly.
173 (mmap_record::alloc_fh): New method.
174 (mmap_record::free_fh): Ditto.
175 (munmap): Use new mmap_record::alloc_fh and mmap_record::free_fh
176 methods to create a correct fhandler.
177 (msync): Ditto.
178 (fixup_mmaps_after_fork): Ditto.
179
c4548fb4
CV
180Mon Apr 16 16:01:00 2001 Corinna Vinschen <corinna@vinschen.de>
181
182 * grp.cc (getgroups): If `allow_ntsec' is set, use the process token
183 information to evaluate the groups list.
184
3b3b19d2
CF
185Mon Apr 16 00:08:02 2001 Christopher Faylor <cgf@cygnus.com>
186
187 * features.h: Remove this file as it is now being supplied by newlib.
188
b0a50cf3
CF
189Sun Apr 15 23:23:29 2001 Christopher Faylor <cgf@cygnus.com>
190
191 * autoload.cc: Add winmm functions needed by fhandler_dsp.cc.
192
193Sun Apr 15 22:53:52 2001 Andy Younger <andylyounger@hotmail.com>
194
195 * fhandler_dsp.cc: New file. Implements OSS like /dev/dsp.
196 * include/sys/soundcard.h: New file. User land includes for OSS
197 /dev/dsp.
198 * fhandler.h: Add new class fhandler_dev_dsp and a FH_OSS_DSP
199 definition.
200 * dtable.cc (dtable::build_fhandler): Allow creation of the /dev/dsp
201 device.
202 * path.cc (windows_device_names): Add /dev/dsp into list of device
203 names.
204 * Makefile.in (DLL_OFILES): Add fhandler_dsp.o.
205
4535e6a9
CF
206Sun Apr 15 16:36:27 2001 Christopher Faylor <cgf@cygnus.com>
207
208 * uname.c (uname): Default n in in86 to 6 if Windows returns > 6.
209
1ff87985
CV
210Sun Apr 15 15:56:00 2001 Corinna Vinschen <corinna@vinschen.de>
211
212 * path.cc (add_ext_from_sym): Redefine to call `add_ext_from_sym_'.
213 (add_ext_from_sym_): New inline function.
214
34bbe838
CF
215Sat Apr 14 19:23:52 2001 Christopher Faylor <cgf@cygnus.com>
216
217 * config.h.in: Turn on VFORK by default.
218
266be1d8
CF
219Sat Apr 14 18:04:35 2001 Christopher Faylor <cgf@cygnus.com>
220
221 * net.cc (cygwin_socket): Set SO_LINGER to small value so closed UNIX
222 domain sockets will not stay around.
223
224Sat Apr 14 18:01:43 2001 Pierre A. Humblet <Pierre.Humblet@ieee.org>
225
226 * select.cc (socket_cleanup): Set SO_LINGER to small value so closed
227 dummy sockets do not stay around. Use correct value for second argument
228 to shutdown.
229
e6b98fc8
RC
230Sat Apr 14 17:04:00 2001 Robert Collins <rbtcollins@hotmail.com>
231
232 * thread.h (MTinterface): Add threadcount.
233 * thread.cc (MTinterface::Init): Set threadcount to 1.
234 (__pthread_create): Increment threadcount.
235 (__pthread_exit): Decrement threadcount and call exit() from the last thread.
236
1114d472 237Fri Apr 13 11:34:24 2001 Robert Collins <rbtcollins@hotmail.com>
39b6859a
CF
238
239 * fork.cc (fork_child): Call the __pthread_atforkchild function.
240 (fork_parent): Call the __pthread_atforkparent function.
241 * cygwin.din: Export pthread_atfork.
242 * thread.h (callback): New class.
243 (MTinterface): Use it.
244 * thread.cc (__pthread_atforkprepare): New function.
245 (__pthread_atforkparent): New function.
246 (__pthread_atforkchild): New function.
247 (__pthread_atfork): New function.
248 * pthread.cc (pthread_atfork): New function.
249
e61cead3
CV
250Fri Apr 13 9:52:00 2001 Corinna Vinschen <corinna@vinschen.de>
251
252 * path.cc (add_ext_from_sym): New define evaluating `known'suffix'.
253 (path_conv::check): Use add_ext_from_sym throughout.
254
255Thu Apr 12 23:19:00 2001 Corinna Vinschen <corinna@vinschen.de>
70c370d6
CV
256
257 * dir.cc (mkdir): Check for case clash.
258 * environ.cc: Add extern declaration for `pcheck_case'.
259 (check_case_init): New function.
260 (struct parse_thing): Add "check_case" option.
261 * errno.cc (_sys_nerrlist): Add text for ECASECLASH.
262 (strerror): Add case branch for ECASECLASH.
263 * fhandler.cc (fhandler_disk_file::open): Check for case clash.
264 * path.cc: Add global variable `pcheck_case'.
265 (struct symlink_info): Add member `case_clash' and method `case_check'.
266 (path_prefix_p_): Call `pathnmatch' instead of `strncasematch'.
267 (pathnmatch): New funtion.
268 (pathmatch): Ditto.
269 (path_conv::check): Add handling for case checking.
270 (symlink): Check for case clash.
271 (symlink_info::check): Add parameter for case checking.
272 Handle case checking.
273 (symlink_info::case_check): New method.
274 (chdir): Don't use unconverted path if pcheck_case==PCHECK_STRICT.
275 * path.h: Add extern declarations for `pathmatch' and
276 `pathnmatch'.
277 (enum case_checking): New enumeration type describing
278 the case checking behaviour of path conversion routines.
279 (class path_conv): Add member `case_clash'.
280 * syscalls.cc (_link): Check for case clash.
281
82d4a5d4
CF
282Thu Apr 12 12:49:53 2001 Christopher Faylor <cgf@cygnus.com>
283
284 * syscalls.cc (mkfifo): New function stub.
285
aa67fd12
CF
2862001-04-12 Robert Collins <rbtcollins@hotmail.com>
287
288 * configure.in: Remove PTH_ALLOW.
289 * cygwin.din: Remove @PTH_ALLOW@ prefixes to pthread functions. Add
290 new pthread exports.
291 * pthread.cc: New wrapper functions for the above new exports.
292 * sched.cc (valid_sched_parameters): New function.
293 (sched_setparam): Use it.
294 (sched_set_thread_priority): New function. Used by pthread_sched*.
295 * thread.cc (pthread_key_destructor::InsertAfter): New function.
296 (pthread_key_destructor::UnlinkNext): New function.
297 (pthread_key_destructor::Next): New function.
298 (pthread_key_destructor_list::Insert): New function.
299 (pthread_key_destructor_list::Remove): New function.
300 (pthread_key_destructor_list::Pop): New function.
301 (pthread_key_destructor::pthread_key_destructor): New function.
302 (pthread_key_destructor_list::IterateNull): New function.
303 (MTinterface::Init): Initialise new member.
304 (pthread::pthread): Initialise new members.
305 (pthread::create): Copy new attributes. Set the new thread priority.
306 (pthread_attr::pthread_attr): Initialise new members.
307 (pthread_key::pthread_key): Setup destructor function.
308 (pthread_key::~pthread_key): Remove destructor function.
309 (pthread_mutexattr::pthread_mutexattr): New function.
310 (pthread_mutexattr::~pthread_mutexattr): New function.
311 (__pthread_once): New function.
312 (__pthread_cleanup): New function.
313 (__pthread_cancel): New function.
314 (__pthread_setcancelstate): New function.
315 (__pthread_setcanceltype): New function.
316 (__pthread_testcancel): New function.
317 (__pthread_attr_getinheritsched): New function.
318 (__pthread_attr_getschedparam): New function.
319 (__pthread_attr_getschedpolicy): New function.
320 (__pthread_attr_getscope): New function.
321 (__pthread_attr_setinheritsched): New function.
322 (__pthread_attr_setschedparam): New function.
323 (__pthread_attr_setschedpolicy): New function.
324 (__pthread_attr_setscope): New function.
325 (__pthread_exit): Call any key destructors on thread exit.
326 (__pthread_join): Use the embedded attr values.
327 (__pthread_detach): Use the embedded attr values.
328 (__pthread_getconcurrency): New function.
329 (__pthread_getschedparam): New function.
330 (__pthread_key_create): Pass the destructor on object creation.
331 (__pthread_key_delete): Correct incorrect prototype.
332 (__pthread_setconcurrency): New function.
333 (__pthread_setschedparam): New function.
334 (__pthread_cond_timedwait): Support static mutex initialisers.
335 (__pthread_cond_wait): Ditto.
336 (__pthread_mutex_getprioceiling): New function.
337 (__pthread_mutex_lock): Support static mutex initialisers.
338 (__pthread_mutex_trylock): Ditto.
339 (__pthread_mutex_unlock): Ditto.
340 (__pthread_mutex_destroy): Ditto.
341 (__pthread_mutex_setprioceiling): New function.
342 (__pthread_mutexattr_getprotocol): New function.
343 (__pthread_mutexattr_getpshared): New function.
344 (__pthread_mutexattr_gettype): New function.
345 (__pthread_mutexattr_init): New function.
346 (__pthread_mutexattr_destroy): New function.
347 (__pthread_mutexattr_setprotocol): New function.
348 (__pthread_mutexattr_setprioceiling): New function.
349 (__pthread_mutexattr_getprioceiling): New function.
350 (__pthread_mutexattr_setpshared): New function.
351 (__pthread_mutexattr_settype): New function. Remove stubs for non
352 MT_SAFE compilation.
353 * thread.h: Remove duplicate #defines. Add prototypes for new
354 functions in thread.cc.
355 (pthread_key_destructor): New class.
356 (pthread_key_destructor_list): New class.
357 (pthread_attr): Add new members.
358 (pthread): Remove members that are duplicated in the pthread_attr
359 class.
360 (pthread_mutex_attr): Add new members.
361 (pthread_once): New class.
362 * include/pthread.h: Add prototypes for new functions exported from
363 cygwin1.dll. Remove typedefs.
364 * include/sched.h: Add prototypes for new functions in sched.cc.
365 * include/cygwin/types.h: Add typedefs from pthread.h
366
fc672fb2
CF
367Tue Apr 10 22:02:53 2001 Christopher Faylor <cgf@cygnus.com>
368
369 * path.cc (struct symlink_info): Add extn and ext_tacked_on fields.
370 (path_conv::check): Only tack on extension if a known one didn't
371 already exist.
372 (suffix_scan::has): Return pointer to known extension.
373 (symlink_info::check): Record location of extension, if any.
374
619f7fa0
ED
3752001-04-09 Egor Duda <deo@logos-m.ru>
376
377 * fhandler.h (class fhandler_socket): Add members and methods to
378 support secure connections on AF_UNIX sockets.
379 * fhandler_socket.cc (fhandler_socket::set_connect_secret): New method.
380 (fhandler_socket::get_connect_secret): Ditto.
381 (fhandler_socket::create_secret_event): Ditto.
382 (fhandler_socket::close_secret_event): Ditto.
383 (fhandler_socket::check_peer_secret_event): Ditto.
384 (fhandler_socket::fixup_after_fork): Duplicate secret event to child.
385 (fhandler_socket::dup): Copy address family.
386 (fhandler_socket::close): Close secret event.
387 * net.cc (get_inet_addr): Read secret cookie.
388 (cygwin_connect): Check if peer knows secret cookie value.
389 (cygwin_accept): Ditto. Copy address family to newly created socket.
390 (cygwin_bind): Generate and write secret cookie.
391 (wsock_init): Initialize random number generator.
392
aa970c61
CF
393Sun Apr 8 20:40:58 2001 Christopher Faylor <cgf@cygnus.com>
394
395 * Makefile.in: Put -lgcc last in list of libraries, since stdc++
396 library needs it.
397 * cygwin.din: Remove obsolete "__empty" export.
398 * exceptions.cc (call_signal_handler_now): Force inclusion of function
399 even when -finline-functions is specified.
400 * sigproc.h: Remove obsolete call_signal_handler declaration.
401
402Sun Apr 8 20:36:55 2001 Benjamin Riefenstahl <Benjamin.Riefenstahl@epost.de>
e3eef4d0 403
aa970c61
CF
404 * fhandler_console.cc (cp_get_internal): New function.
405 (cp_convert): New function.
406 (con_to_str): New function.
407 (str_to_con): New function.
408 (fhandler_console::read): Replace OemToCharBuff with con_to_str.
409 (fhandler_console::write_normal): Replace CharToOemBuff with str_to_con.
410
9ddfe5a0
CV
411Thu Apr 5 22:41:00 2001 Corinna Vinschen <corinna@vinschen.de>
412
413 * syscalls.cc (stat_worker): Fix conditional which still allowed
414 successful stat'ing of non-existant files.
415
0403bb74
CF
416Wed Apr 4 10:37:44 2001 Christopher Faylor <cgf@cygnus.com>
417
418 * child_info.h: Bump magic number for fork/exec/spawn.
419
c196a1a2
CV
420Tue Apr 3 20:06:00 2001 Corinna Vinschen <corinna@vinschen.de>
421
422 * errno.cc (errmap): Map ERROR_FILE_INVALID to ENXIO.
423
c90e420d
CF
424Mon Apr 2 22:48:58 2001 Christopher Faylor <cgf@cygnus.com>
425
426 * cygrun.c (main): Fix compiler warning.
427 * gmon.c (_mcleanup): Ditto.
428 * profil.c (profile_off): Ditto.
429
430 * net.cc (find_winsock_errno): New function.
431 (__set_winsock_errno): Use find_winsock_errno.
432 (cygwin_setsockopt): Detect SO_ERROR for debugging.
433 (cygwin_getsockopt): Ditto. Translate error when getsockopt returns
434 SO_ERROR.
435 * winsup.h: regparmize __set_winsock_errno.
436 * include/sys/strace.h: Document that strace functions can't use
437 regparm.
438
0f0a7dc9
CV
4392001-04-02 Kazuhiro Fujieda <fujieda@jaist.ac.jp>
440
441 * fhandler.cc (fhandler_disk_file::open): Avoid checking a magic
442 number of a directory.
443
f97adf98
CF
444Mon Apr 2 00:24:08 2001 Christopher Faylor <cgf@cygnus.com>
445
446 * shared_info.h (mount_info): Remove mnt_ elements.
447 * thread.h (struct _winsup_t): Add mnt_ elements.
448 * path.cc (fillout_mntent): Use mnt_ elements from reent_winsup ().
449
1ba3935d
CF
450Sun Apr 1 20:10:34 2001 Christopher Faylor <cgf@cygnus.com>
451
452 * exceptions.cc (sigframe::call_signal_handler): Return value of
453 call_signal_handler_now.
454 * sigproc.h (sigframe): Use constructor.
455 * syscalls.cc (_read): Correct errno test prior to calling signal
456 handler.
457
2a1743c7
CF
458Sun Apr 1 00:38:06 2001 Christopher Faylor <cgf@cygnus.com>
459
0ef785e4 460 * exceptions.cc (sigframe::call_signal_handler): Move outside of "C"
2a1743c7
CF
461 block or some compilers will complain.
462
11f3a79b
CF
463Sun Apr 1 00:24:14 2001 Christopher Faylor <cgf@cygnus.com>
464
465 * exceptions.cc (call_signal_handler_now): Rename from
466 call_signal_handler to avoid C++ confusion.
467
5817ee2d
CF
468Sun Apr 1 00:08:15 2001 Christopher Faylor <cgf@cygnus.com>
469
470 * path.cc (fillout_mntent): Always remove drive root directories from
471 future consideration by "/cygdrive" reporting.
472 (cygdrive_getmnt): Avoid reporting removable drives or drives with no
473 media mounted.
474
f2aeff27
CF
475Sat Mar 31 21:56:19 2001 Christopher Faylor <cgf@cygnus.com>
476
477 * thread.h (struct _winsup_t): Remove obsolete elements. Add
478 available_drives element.
479 * path.cc (mount_info::getmntent): Report "/cygdrive" drives when
480 mounted drives are exhausted.
481 (fillout_mntent): New function.
482 (mount_item::getmntent): Use fillout_mntent.
483 (cygdrives_mntent): New function. Returns next available "/cygdrive".
484 (setmntent): Initialize available "/cygdrives".
485 * syscalls.cc: Remove some if 0'ed code.
486 * times.cc (timezone): Use more descriptive variable name.
487
f6111483
CF
488Sat Mar 31 18:59:52 2001 Christopher Faylor <cgf@cygnus.com>
489
490 * sigproc.h (class sigframe): Implement 'unregister()' method.
491 (sigframe::~sigframe): Use unregister method.
492 (sigframe::call_signal_handler): Declare new method.
493 * exceptions.cc (sigframe::call_signal_handler): New method.
494 Unregisters current sigframe before calling signal handler.
495 (setup_handler): Clear waiting threads prior to arming signal_arrived.
496 * syscalls.cc (_read): Change goto to loop. Recalculate sigframe
497 inside of loop so that constructor is called when appropriate.
498 * wait.cc (wait4): Ditto.
499
500 * signal.cc: Change "sig" to "signal" in debugging messages throughout.
501 * sigproc.cc: Ditto.
502
ab57d146
CF
503Sat Mar 31 17:12:08 2001 Christopher Faylor <cgf@cygnus.com>
504
505 * fhandler_serial.cc (fhandler_serial::raw_write): Close protected
506 handles with ForceCloseHandle or suffer spurious warnings.
507
0cec3226
CF
508Sat Mar 31 16:23:32 2001 Christopher Faylor <cgf@cygnus.com>
509
510 * fhandler.cc (fhandler_base::read): Remove special handling of CTRL-Z.
511
70afbaae
CV
512Sat Mar 31 11:09:00 2001 Corinna Vinschen <corinna@vinschen.de>
513
514 * fhandler.h (class fhandler_console): Add members `insert_mode'.
515 * fhandler_console.cc (fhandler_console::dup): Duplicate `insert_mode'.
516 (fhandler_console::fhandler_console): Initialize `insert_mode'.
c796f4f1 517 (fhandler_console::char_command): Add terminal capabilities
70afbaae
CV
518 "enter insert mode" = \E[4h and "exit insert mode" = \E[4l.
519 Care for insert mode on terminal capability "repeat char" = \E[x;yb.
520 (fhandler_console::write_normal): Care for insert mode before writing
521 to the console.
522 (array keytable): Add keymapping for modified cursor and control
523 block keys (xterm like).
524
f42da31a
CV
525Fri Mar 30 13:02:00 2001 Corinna Vinschen <corinna@vinschen.de>
526
527 * fhandler.h (class fhandler_console): Add members `savebufsiz' and
528 `savebuf' to allow save/restore of screen.
70afbaae
CV
529 * fhandler_console.cc (fhandler_console::dup): Duplicate `savebufsiz'
530 and `savebuf'.
f42da31a
CV
531 (fhandler_console::fhandler_console): Initialize `savebufsiz' and
532 `savebuf'.
533 (fhandler_console::char_command): Add terminal capabilities
534 "save screen content" = \E[?47h and "restore screen content" = \E[?47l.
535
b5eb3d0f
CF
536Wed Mar 28 19:28:50 2001 Christopher Faylor <cgf@cygnus.com>
537
538 * path.cc (chdir): Eat trailing whitespace on input path.
539
1ac6d1a1
CF
540Tue Mar 27 22:38:42 2001 Christopher Faylor <cgf@cygnus.com>
541
542 * lib/_cygwin_S_IEXEC.c: Remove "const" from globals or they never seem
543 to be defined. Wrap definitions in extern "C". Include winsup.h to
544 assure proper definitions.
545
546 * dcrt0.cc (dll_crt0_1): Call stdio_init after premain run so that
547 binmode.o, etc., will control default stdio settings.
548 * dtable.cc (dtable::init_std_file_from_handle): Allow __fmode to force
549 binmode/textmode settings. Default pipes to binmode.
550
37a2d97a
CV
551Tue Mar 27 11:31:00 2001 Corinna Vinschen <corinna@vinschen.de>
552
553 * mmap.cc (mmap): Fix conditional for previous patch.
554
1636a5a1
CV
555Mon Mar 26 18:48:00 2001 Corinna Vinschen <corinna@vinschen.de>
556
557 * mmap.cc (mmap): Outflank copy-on-write problem on 9x by
558 setting access mode to FILE_MAP_READ when read access is requested.
559
aa73152e
CF
560Sun Mar 25 20:12:21 2001 Christopher Faylor <cgf@cygnus.com>
561
562 * dlfcn.cc (check_access): Eliminate.
563 (check_path_access): Use passed in path_conv buf.
564 (get_full_path_of_dll): Use passed in name buf to avoid a static. Rip
565 out most of the path checking since LoadLibrary will do all of this
566 automatically.
567 (dlopen): Set errno when appropriate (may not be compliant?).
568 * environ.cc (posify): Don't pass in "native" path if it seems to
569 actually be posix.
570
db0421f6
CF
571Thursday Mar 22 2001 Robert Collins <rbtcollins@hotmail.com>
572
573 * fhandler.h (fhandler_dev_clipboard): Extend to support writing.
574 * fhandler_clipboard.cc (fhandler_dev_clipboard::fhandler_dev_clipboard):
575 Initialize new fields. Open clipboard here.
576 (fhandler_dev_clipboard::dup): New method.
577 (fhandler_dev_clipboard::open): Accomodate new fields. Register
578 clipboard here, if appropriate.
579 (set_clipboard): New function. Moves buffer to clipboard.
580 (fhandler_dev_clipboard::write): Truly implement clipboard writing.
581 (fhandler_dev_clipboard::read): Reimplement to allow successive reads.
582 (fhandler_dev_clipboard::lseek): Truly implement seeks in clipboard.
0ed560cb
CF
583 (fhandler_dev_clipboard::close): Clear out new fields. Support
584 sequential reads and sequential writes. Support for binary data via a
585 native clipboard format.
db0421f6 586
0b30bad4 5872001-03-22 Egor Duda <deo@logos-m.ru>
0cec3226 588
0b30bad4
CF
589 * fhandler_console.cc (fhandler_console::set_default_attr): Update
590 console color attributes on tty reset.
591
c4458148
CF
592Wed Mar 21 22:12:36 2001 Christopher Faylor <cgf@cygnus.com>
593
594 * autoload.cc (kernel32_init): New function for kernel32 autoload
595 initialization.
596 (SignalObjectAndWait): Add conditional load of this function when it is
597 available.
598
9a08b2c0
CF
5992001-03-21 Robert Collins <rbtcollins@hotmail.com>
600
601 * sched.cc: New file. Implement sched*.
602 * include/sched.h: New file. User land includes for sched*.
603 * Makefile.in: Add sched.o
604 * cygwin.din: Add exports for sched*.
605
a1299ba5
CF
606Tue Mar 20 14:48:46 2001 Christopher Faylor <cgf@cygnus.com>
607
608 * dtable.cc: Guard against new winsock.h/winsock2.h warnings when
609 mixing winsock*.h and sys/types.h.
610 * fhandler_socket.cc: Ditto.
611 * net.cc: Ditto.
612 * select.cc: Ditto.
613 * exceptions.cc: Remove unneeded define.
614
b8c8fa17
CF
615Mon Mar 19 17:43:29 2001 Christopher Faylor <cgf@cygnus.com>
616
617 * exceptions.cc (interruptible): Update debugging output.
618 (setup_handler): Ensure that wait_sig loop wakes up when we punt on
619 sending a signal.
620 * poll.cc (poll): Add signal guard here.
621
78ace8a7
ED
6222001-03-19 Egor Duda <deo@logos-m.ru>
623
624 * tty.h (tty::create_inuse): Add new parameter to allow non-
625 inheritable 'inuse' events.
626 * tty.cc (tty::create_inuse): Use new parameter.
627 * fhandler_tty.cc (fhandler_tty_master::init): Ditto.
628 * fhandler_tty.cc (fhandler_pty_master::open): Ditto.
629 * fhandler_tty.cc (fhandler_tty_master::init): Create master_alive
630 event.
631 * tty.cc (tty_list::terminate): Close master_alive event.
632 * fhandler_tty.cc (fhandler_tty_common::close): Send EOF to slaves
633 when master side is closed.
634
98750a84
CV
635Mon Mar 19 14:32:00 2001 Corinna Vinschen <corinna@vinschen.de>
636
637 * mmap.cc (map::get_list_by_fd): Avoid calling `get_namehash' when
638 file descriptor is -1.
639
30f326bf
CV
640Sat Mar 17 18:30:00 2001 Corinna Vinschen <corinna@vinschen.de>
641
642 * syscalls.cc (check_posix_perm): New static function.
643 (fpathconf): Add _PC_POSIX_PERMISSIONS and _PC_POSIX_SECURITY
644 support.
645 (pathconf): Ditto.
646 * include/cygwin/version.h: Bump API minor number to 37.
647
5e8e21d9
ED
6482001-03-18 Egor Duda <deo@logos-m.ru>
649
650 * fhandler.h (fhandler_tty_slave): Declare new methods.
651 * select.cc (fhandler_tty_slave::select_read): New method.
652 * select.cc (fhandler_tty_slave::ready_for_read): Ditto.
653 * select.cc (verify_tty_slave): New function.
654 * fhandler_termios.cc (fhandler_termios::line_edit): Empty input
655 buffer on signal.
656 * fhandler_tty.cc (fhandler_tty_slave::read): Check for input data
657 after reading from pipe. Reset event if input pipe is empty.
658 * tty.h (class tty): Allow creating events with manual reset.
659 * tty.cc (tty::get_event): Use manual_reset flag.
660 * tty.cc (tty::common_init): Create input_available_event with
661 manual reset.
662
00a74961
CF
663Sat Mar 17 21:48:03 2001 Christopher Faylor <cgf@cygnus.com>
664
665 * external.cc (fillout_pinfo): Match windows pid, as well as cygwin pid
666 when passed in pid. Don't prematurely break when searching for a pid.
667
668 * thread.h (_winsup_t): Eliminate unneeded field.
669
8eb72e63
CV
670Sat Mar 17 20:46:00 2001 Corinna Vinschen <corinna@vinschen.de>
671
672 * net.cc (get_95_ifconf): Use strcasematch instead of strcasecmp.
673 * syscalls.cc (_unlink): Ditto.
674 (_rename): Ditto.
675
57499703
CF
676Sat Mar 17 12:43:15 2001 Christopher Faylor <cgf@cygnus.com>
677
678 * path.cc (suffix_scan::next): Avoid searching for foo.lnk twice when
679 input is "foo".
680
298fad46
CV
681Sat Mar 17 18:10:00 2001 Corinna Vinschen <corinna@vinschen.de>
682
683 * net.cc (cygwin_socket): Set protocol to 0 when address family is
684 AF_UNIX to avoid WSAEPROTONOSUPPORT error.
685
f52488f7
CV
686Sat Mar 17 09:51:32 2001 Mathew Brozowski <brozow@tavve.com>
687
688 * net.cc (cygwin_socket): Pass protocol parameter to socket call.
689
b63a3f55
CF
690Sat Mar 17 02:05:38 2001 Christopher Faylor <cgf@cygnus.com>
691
692 * dir.cc (readdir): Use strcasematch for consistency.
693 * path.cc (symlink_info): Eliminate known_suffix.
694 (path_conv::check): Always copy ext_here to end of buffer, if found.
695 (suffix_scan): Eliminate ext_here, add suffixes_start.
696 (suffix_scan::has): Eliminate an argument. Reorganize. Always return
697 pointer to end of input path.
698 (suffix_scan::next): Take a second pass through the suffix list looking
699 for .lnk.
700 (symlink_info::check): Eliminate known_suffix usage.
701
db15b3e3 702Sat Mar 17 00:10:52 2001 Christopher Faylor <cgf@cygnus.com>
5bb22c6b 703
db15b3e3 704 * syscalls.cc (stat_dev): Give devices full read/write by default.
5bb22c6b 705
c0c9de3c
CF
706Saturday Mar 17 3:45 2001 Robert Collins <rbtcollins@hotmail.com>
707
708 * thread.cc (MTinterface::CreateCond): Check for null attr pointer.
709
ddca580f
CF
710Fri Mar 16 21:13:23 2001 Christopher Faylor <cgf@cygnus.com>
711
712 * fhandler_termios.cc (fhandler_termios::line_edit): Don't accept input
713 when a signal is sent or we'll end up in an EOF/signal race.
714
b65c6896
CF
715Fri Mar 16 20:25:40 2001 Christopher Faylor <cgf@cygnus.com>
716
717 * path.cc: Translate scan states from defines to enums.
718 (suffix_scan): Rename state to nextstate for clarity.
719 (lnk_match): Change to allow multiple states to indicate that a .lnk
720 has been matched.
721 (suffix_scan::has): Eliminate a goto. Handle .lnk as a special case,
722 since a .lnk may also need to be tacked on the end of a .lnk.
723 (suffix_scan::next): Don't increment next state. Set it specifically.
724 Recognize new .lnk states.
725
92f4bf97 726Saturday Mar 17 01:19 2001 Robert Collins rbtcollins@hotmail.com
0cec3226 727
5ccbf4b6
CF
728 * cygwin.din: Export the new functions.
729 * pthread.cc (pthread_cond_*): Add wrapper functions that call
730 __pthread_cond* functions.
731 * thread.cc (__pthread_cond_*): Implement the pthread_cond* functions.
732 * thread.h: Add new class entries and prototypes for __pthread_cond*
733 functions.
734 * include/pthread.h: user land header prototypes for pthread_cond*
735 functions and related defines.
736
e212576d
CV
737Wed Mar 14 16:30:00 2001 Corinna Vinschen <corinna@vinschen.de>
738
739 * environ.cc (parse_options): Use strtok_r instead of strtok.
740 * security.cc (convert_string_sid_to_sid): Ditto.
741 (aclfromtext): Ditto. Fix buffer usage.
742
78d2c08c
CV
743Wed Mar 14 10:11:00 2001 Corinna Vinschen <corinna@vinschen.de>
744
745 * path.cc (lnk_suffixes): Remove.
746 (class suffix_scan): Add `lnk_state' flag.
747 (suffix_scan::lnk_match): Return state of `lnk_state' now.
748 (suffix_scan::has): Changed behaviour if file has `.lnk' suffix.
749 (suffix_scan::next): Set `lnk_state' where appropriate.
750 (symlink_info::check): Fix a wrong `break'.
751 * syscalls.cc (chown_worker): Change debug statement to reflect
752 lchown fix.
753 (lchown): Call chown_worker with `PC_SYM_NOFOLLOW' instead of
754 `PC_SYM_IGNORE'.
755
1d39c83a
CV
756Tue Mar 13 13:52:00 2001 Corinna Vinschen <corinna@vinschen.de>
757
758 * fhandler.cc (fhandler_disk_file::fstat): Add correct modes to
759 symlinks when stat'ing on FAT or FAT32 file systems.
760
e935fcf0
ED
7612001-03-12 Egor Duda <deo@logos-m.ru>
762
763 * fhandler.h (fhandler_termios::fixup_after_exec): New function.
344ce60c
ED
764 * fhandler_termios.cc (fhandler_termios::fixup_after_fork): New
765 function. Fixup output handle.
e935fcf0
ED
766 * fhandler_tty.cc (fhandler_tty_common::fixup_after_fork): Output
767 handle is now fixed up in fhandler_termios::fixup_after_fork().
768
79409dc0
ED
7692001-03-12 Egor Duda <deo@logos-m.ru>
770
771 * fhandler.h (fhandler_termios::fhandler_termios): Enable fixup
772 after fork.
773 * fhandler_console.cc (fhandler_console::fhandler_console): Fixup
774 after fork is now enabled in the base class constructor.
775
2b777e2e
CF
776Mon Mar 12 11:19:41 2001 Christopher Faylor <cgf@cygnus.com>
777
778 * mkvers.sh: Include config.h so that DEBUGGING is correctly defined.
779
941fa5ad
CF
780Mon Mar 12 09:47:55 2001 Christopher Faylor <cgf@cygnus.com>
781
782 * spawn.cc (spawn_guts): Don't set EXIT_REPARENTING if parent process
783 is not a cygwin process (suggested by Jason Gouger
784 <cygwin@jason-gouger.com>).
785
d0909d91
CF
786Sun Mar 11 16:00:58 2001 Christopher Faylor <cgf@cygnus.com>
787
788 * child_info.h: Bump magic number for fork/exec/spawn.
789
2116a175
CF
790Sat Mar 10 20:54:47 2001 Christopher Faylor <cgf@cygnus.com>
791
792 * autoload.cc (noload): Use proper method for multiline strings or
793 newer gcc's complain.
794 * exceptions.cc (unused_sig_wrapper): Ditto.
795 * fhandler.h (fhandler_base): Make get_io_handle and friends return
796 self.
797 * fhandler_tty.cc (fhandler_pty_common::close_on_exec): Accomodate
798 DEBUGGING flag to avoid spurious warnings when inheritance is set.
799
7cf3b655
CF
800Sat Mar 10 16:52:12 2001 Christopher Faylor <cgf@cygnus.com>
801
802 * shortcut.c (PATH_ALL_EXEC): Add parentheses to avoid a compiler
803 warning.
804
805 * exceptions.cc (setup_handler): Clarify debugging message.
806 * sigproc.cc (proc_subproc): Remove PROC_CHILDSTOPPED test. It is
807 handled by normal PROC_CLEARWAIT case.
808 (wait_sig): Eliminate "dispatched" tracking. Remove __SIGCHILDSTOPPED
809 test. Decrement counter again before jumping out of
810 InterlockedDecrement loop so that subsequent InterlockedIncrement will
811 keep the counter at the correctly decremented value and also detect
812 when there are pending signals.
813 * sigproc.h: Remove __SIGCHILDSTOPPED element.
814 (procstuff): Remove PROC_CHILDSTOPPED element.
815
e2f2a27e
CF
816Sat Mar 10 15:22:44 2001 Christopher Faylor <cgf@cygnus.com>
817
818 * syscalls.cc (_rename): Set errno to ENOENT when an old path doesn't
819 exist (from Kazuhiro Fujieda <fujieda@jaist.ac.jp>). Also set EACCES
820 when directory is not writable.
821
6ebccdc1
CF
822Wed Mar 7 15:49:47 2001 Christopher Faylor <cgf@cygnus.com>
823
824 * syscalls.cc (_read): Change definition to return ssize_t to be
825 consistent with read.
826 (_write): Change definition to return ssize_t to be consistent with
827 write.
828
efd76e41
CF
829Wed Mar 7 01:08:21 2001 Christopher Faylor <cgf@cygnus.com>
830
831 * sigproc.h (sigthread): Declare new methods. Create new winapi_lock
832 field.
833 (sigframe:;set): Call get_winapi_lock after frame is set so that signal
834 handler thread knows not to call SuspendThread.
835 (sigframe::~sigframe): Release winapi_lock.
836 * exceptions.cc (sigthread::get_winapi_lock): New method.
837 (sigthread::release_winapi_lock): New method.
838 (setup_handler): Use get_winapi_lock to ensure that signalled thread is
839 not blocked in a Windows API.
840
841 * path.h (path_types): Avoid broken GCC warning.
842
bf11a54f
CV
843Tue Mar 6 14:02:00 2001 Corinna Vinschen <corinna@vinschen.de>
844
845 * path.cc (suffix_scan::has): Change order of conditionals
846 to allow checking for .lnk suffixes even if in_suffixes is empty.
847
848Tue Mar 6 13:02:00 2001 Corinna Vinschen <corinna@vinschen.de>
7cdc9fee
CV
849
850 * autoload.c (cygwin_premain0): Add missing parameter.
851 * binmode.c (cygwin_premain0): Ditto.
852 * textmode.c (cygwin_premain0): Ditto.
853
854Tue Mar 6 12:04:00 2001 Jason Tiller <jtiller@sjm.com>
855
856 * auto_load.cc: Add "GetKeyboardLayout" entry in the list of
857 Win32 User32.DLL exports to provide.
858 * fhandler.h (class fhandler_console): Add meta_mask private
859 member to remember which keystroke modifiers should generate
860 META.
861 * fhandler_console.cc (fhandler_console::read): Modify code that
862 tests a keystroke for a META-escaped key to use the 'meta_mask'
863 variable.
864 (fhandler_console::fhandler_console): Add definition for
865 variable "meta_mask" used to determine if a keystroke should be
866 preceded by META in the client console stream. Set meta_mask
867 based on whether or not user's keyboard language is English -
868 non-English keyboards pass AltGr (right <ALT>) unmolested,
869 whereas English keyboards now interpret left- and right-<ALT>
870 as META.
871
a887211b
CV
872Mon Mar 5 20:15:00 2001 Corinna Vinschen <corinna@vinschen.de>
873
874 * include/a.out.h: Add copyright hint.
875 * include/fcntl.h: Ditto.
876 * include/lastlog.h: Ditto.
877 * include/memory.h: Ditto.
878 * include/mntent.h: Ditto.
879 * include/paths.h: Ditto.
880 * include/poll.h: Ditto.
881 * include/syslog.h: Ditto.
882 * include/termio.h: Ditto.
883 * include/tzfile.h: Ditto.
884 * include/arpa/inet.h: Ditto.
885 * include/asm/byteorder.h: Ditto.
886 * include/asm/socket.h: Ditto.
887 * include/asm/types.h: Ditto.
888 * include/cygwin/if.h: Ditto.
889 * include/cygwin/mtio.h: Ditto.
890 * include/cygwin/rdevio.h: Ditto.
891 * include/cygwin/socket.h: Ditto.
892 * include/net/if.h: Ditto.
893 * include/netinet/in.h: Ditto.
894 * include/netinet/in_systm.h: Ditto.
895 * include/netinet/ip.h: Ditto.
896 * include/netinet/ip_icmp.h: Ditto.
897 * include/netinet/tcp.h: Ditto.
898 * include/sys/cdefs.h: Ditto.
899 * include/sys/cygwin.h: Ditto.
900 * include/sys/ioctl.h: Ditto.
901 * include/sys/mman.h: Ditto.
902 * include/sys/mount.h: Ditto.
903 * include/sys/mtio.h: Ditto.
904 * include/sys/procfs.h: Ditto.
905 * include/sys/resource.h: Ditto.
906 * include/sys/smallprint.h: Ditto.
907 * include/sys/socket.h: Ditto.
908 * include/sys/strace.h: Ditto.
909 * include/sys/syslog.h: Ditto.
910 * include/sys/sysmacros.h: Ditto.
911 * include/sys/termio.h: Ditto.
912 * include/sys/termios.h: Ditto.
913 * include/sys/uio.h: Ditto.
914 * include/sys/un.h: Ditto.
915 * include/sys/utsname.h: Ditto.
916 * include/sys/vfs.h: Ditto.
917 * include/sys/wait.h: Ditto.
918 * regexp/regerror.c: Ditto.
919 * regexp/regexp.h: Ditto.
920 * regexp/regmagic.h: Ditto.
921
95a8465b
CF
922Mon Mar 5 01:25:03 2001 Christopher Faylor <cgf@cygnus.com>
923
924 * dlopen.c (dlopen): Return NULL when name is NULL (suggested by
925 chrisiasci@aol.com).
926
927 * cygwin.din: Add a new, internally used export -
928 _check_for_executable.
929 * dcrt0.cc (dll_crt0_1): Set _check_for_executable for older binaries.
930 Pass user_data to premain functions.
931 * fhandler.cc (fhandler_disk_file::open): Only check for executable if
932 the linked program is intereested in the executable bit.
933 (fhandler_disk_file::check_execable_p): Delete.
934 * fhandler.h (executable_states): New enumeration of various states of
935 executable bit caring.
936 (fhandler_base::set_execable_p): New method.
937
938 * fhandler_termios.cc (fhandler_termios::line_edit): Flag when a signal
939 has been sent to the tty. Return -1 when this is so.
940 * fhandler_console.cc (fhandler_console::read): Return -1 when signal
941 sending character encountered.
942
943 * path.cc (path_conv::check): Record when path refers to a disk device.
944 Move executable extension check here.
945 (check_sysfile): Accomodate new EXEC path states.
946 (has_suffix): Remove.
947 (next_suffix): Remove.
948 (class suffix_scan): New clas.
949 (suffix_scan::has): New method.
950 (suffix_scan:next): New method.
951 (symlink_info::check): Use suffix_scan method to control for scanning
952 for suffixes.
953 * path.h (path_conv::exec_state): New method.
954 * perprocess.h: Make "C" friendly.
955 * include/cygwin/version.h: Define CYGWIN_VERSION_CHECK_FOR_S_IEXEC.
956 Bump CYGWIN_VERSION_API_MINOR.
957 * include/sys/cygwin.h: Change premain declarations.
958
959 * winsup.h: Move __cplusplus test to after builtin defines.
960
306c4b67
ED
9612001-03-04 Egor Duda <deo@logos-m.ru>
962
963 * fhandler.h (class fhandler_tty_common): New mutex and event to
964 syncronize input on master tty with slave tty.
965 * fhandler_tty.cc (fhandler_pty_master::accept_input): Use them to
966 syncronize with slave.
967 * fhandler_tty.cc (fhandler_tty_slave::read): Use input mutex and
968 event to syncronize with master. Do not limit amount of data read
969 from master to vmin value. Interrupt on signal and return already
970 read data, if any.
971 * fhandler_tty.cc (fhandler_tty_slave::open): Handle input mutex and
972 event.
973 * fhandler_tty.cc (fhandler_tty_common::close): Ditto.
974 * fhandler_tty.cc (fhandler_tty_common::set_close_on_exec): Ditto.
975 * fhandler_tty.cc (fhandler_tty_common::fixup_after_fork): Ditto.
976 * fhandler_tty.cc (fhandler_tty_common::dup): Ditto.
977 * tty.h (tty::open_input_mutex): New function.
978 * tty.cc (tty::common_init): Create input mutex and event.
979
ed94def2
CV
980Fri Mar 2 13:32:00 2001 Corinna Vinschen <corinna@vinschen.de>
981
982 * dir.cc (readdir): Fix creating path in symlink check.
983
e03f5f73
CV
984Fri Mar 2 12:33:00 2001 Corinna Vinschen <corinna@vinschen.de>
985
986 * dir.cc (readdir): Fix shortcut==symlink condition.
987 * environ.cc: Add extern decl for `allow_winsymlinks'.
988 (struct parse_thing): Add entry for `[no]winsymlinks'.
989 * path.cc (symlink): Change to be able to create both,
990 symlink==shortcut and symlink==systemfile, dependent of
991 the setting of `allow_winsymlinks'.
992 * security.cc (cygwin_logon_user): Add debug output.
993 * shortcut.c: Add defines from path.h.
994 (has_exec_chars): Copy from path.h.
995 (check_shortcut): Check for executable file condition if not a
996 shortcut.
997
903c330d
CF
998Thu Mar 1 21:06:07 2001 Christopher Faylor <cgf@cygnus.com>
999
1000 * exceptions.cc (sig_handle_tty_stop): Ignore attempts to suspend a
1001 process if started by non-cygwin parent.
1002
d80999a1
CF
1003Thu Mar 1 20:48:11 2001 Christopher Faylor <cgf@cygnus.com>
1004
1005 * select.cc (peek_console): Don't report read_ready on mouse events
1006 unless we are looking for mouse events.
1007 * fhandler.h (fhandler_console::mouse_aware): New method.
1008
2de76014
CV
1009Wed Feb 28 15:10:00 2001 Corinna Vinschen <corinna@vinschen.de>
1010
1011 * uinfo.cc: Eliminate `#include <wchar.h>'.
1012
739db26a
ED
10132001-02-28 Egor Duda <deo@logos-m.ru>
1014
1015 * fhandler_floppy.cc (fhandler_dev_floppy::lseek): Determine
1016 drive geometry or partition size to allow seeking from the end of
1017 raw floppy device. Don't allow positioning past the end of media or
1018 to offsets bigger then max off_t.
1019
a53136cc
ED
10202001-02-27 Egor Duda <deo@logos-m.ru>
1021
1022 * fhandler.h (class fhandler_console): Make all variables that
1023 describe "state" of console to be members of fhandler_console.
1024 default_color is now the color which is set when console recieves
1025 reset command.
1026 * fhandler_console.cc (fhandler_console::fhandler_console): Turn
1027 mouse handling and raw keyboard mode off by default. Initialize
1028 state information.
1029 * fhandler.cc (fhandler_console::set_raw_win32_keyboard_mode): New
1030 function.
1031 * fhandler_console.cc (fhandler_console::set_default_attr): New
1032 function. Reset console attributes to default values.
1033 * fhandler_console.cc (fhandler_console::open): Reset attributes.
1034 * fhandler_console.cc (fhandler_console::get_win32_attr): New function.
1035 Calculate win32-style console attribute based on terminal attributes.
1036 * fhandler_console.cc (fhandler_console::set_cursor_maybe): Use
1037 member variable.
1038 * fhandler_console.cc (fhandler_console::read): If in raw-win32
1039 keyboard mode, encode win32 keyboard events in \033{x;y;z;t;u;wK
1040 sequences.
1041 * fhandler_console.cc (fhandler_console::dup): Copy all state
1042 information to the dup()ed handle.
1043 * fhandler_console.cc (fhandler_console::scroll_screen): Use current
1044 fill-in attribute.
1045 * fhandler_console.cc (fhandler_console::clear_screen): Ditto.
1046 * fhandler_console.cc (fhandler_console::char_command): Check if we
1047 saw '?' symbol by member variable. Set terminal attributes on \033[Xm
1048 commands. \033[24m - turn off underline mode, \033[27m - turn off
1049 reverse mode, \033[39m - restore default foreground color.
1050 \033[49m - restore default background color. \033[2000h - turn on raw
1051 keyboard mode, \033[2000l - turn off raw keyboard mode.
1052 * fhandler_console.cc (fhandler_console::write): Set attribues to
1053 default values on reset command.
1054
5b331f1e 10552001-02-26 Mike Simons <msimons@moria.simons-clan.com>
efd76e41 1056
5b331f1e
CF
1057 * times.cc (settimeofday): Replace function stub with working code.
1058
88429768
CV
1059Mon Feb 26 10:42:00 2001 Corinna Vinschen <corinna@vinschen.de>
1060
1061 * strace.cc (strace::vprntf): Move prntf functionality to this function
1062 adding an va_list interface to strace.
1063 (strace::printf): Calls strace::vprntf now.
1064 (strace_printf): New function providing an extern "C" interface to
1065 trace output.
1066 * include/sys/strace.h: Make plain C clean.
1067 (class strace): Add `vprntf' method.
1068
6626ebfe
CV
1069Mon Feb 26 0:10:00 2001 Corinna Vinschen <corinna@vinschen.de>
1070
1071 * shortcut.c: Remove #include <sys/strace.h>.
1072
649033a8
CV
1073Sun Feb 25 10:32:00 2001 Corinna Vinschen <corinna@vinschen.de>
1074
1075 * path.cc (symlink): Add a ".lnk" suffix regardless. Add a comment.
1076
80ed95f2
CV
1077Sun Feb 25 10:18:00 2001 Corinna Vinschen <corinna@vinschen.de>
1078
649033a8 1079 * shortcut.c (check_shortcut): Change symlink condition.
80ed95f2 1080
675412e9
CV
1081Fri Feb 23 10:42:00 2001 Corinna Vinschen <corinna@vinschen.de>
1082
1083 * mmap.cc (fhandler_disk_file::mmap): Use `addr' correctly.
1084 * fhandler_mem.cc (fhandler_dev_mem::mmap): Ditto.
1085
ff413a98
CV
1086Thu Feb 22 17:09:00 2001 Corinna Vinschen <corinna@vinschen.de>
1087
1088 * path.cc (symlink): Keep relative paths relative in the DOS
659b480b
CV
1089 path inside of a shortcut. If that's impossible or the target
1090 path is already absolute save an absolute path.
ff413a98 1091
c5a4eacc
CV
1092Thu Feb 22 15:33:00 2001 Corinna Vinschen <corinna@vinschen.de>
1093
1094 * cygerrno.h: Revert previous patch.
1095 * errno.cc: Ditto.
1096 * dir.cc: Eliminate `dir_suffixes'.
1097 (opendir): Remove usage of `dir_suffixes'.
1098 (rmdir): Ditto.
1099 * fhandler.cc (fhandler_disk_file::open): Remove usage of
1100 `inner_suffixes'.
1101 * path.cc: Rename `inner_suffixes' to `lnk_suffixes'.
1102 (path_conv::check): Remove usage of `inner_suffixes'.
1103 (symlink): Ditto.
1104 (symlink_info::check): Handle checking for `.lnk' in path_conv
1105 exclusively here.
1106 (chdir): Remove usage of `dir_suffixes'.
1107 * shortcut.c: Eliminate debug_printf lines.
1108 (check_shortcut): Don't set error except on failing ReadFile.
1109 * spawn.cc: Remove ".lnk" from `std_suffixes'.
1110 * syscalls.cc (_unlink): Remove usage of `inner_suffixes'.
1111 Remove ".lnk" from `stat_suffixes'.
1112 (_rename): Add check for renaming a symlink to keep the ".lnk"
1113 suffix after renaming.
1114
79e56091
CV
1115Thu Feb 22 13:38:00 2001 Corinna Vinschen <corinna@vinschen.de>
1116
1117 * shortcut.c: New file. Provides a C interface to reading of
1118 Windows shortcuts to avoid compiler flag `-fvtable-thunks'.
1119 * shortcut.h: Ditto.
1120 * Makefile.in: Add shortcut.o to DLL_OFILES.
1121 * cygerrno.h: Provide a C interface to `geterrno_from_win_error' for
1122 using in shortcut.c.
1123 * errno.cc (geterrno_from_win_error): Define as extern "C".
1124 * path.cc (struct symlink_info): Remove methods `check_shortcut' and
1125 `check_sysfile'.
1126 (shortcut_header): Move to shortcut.c.
1127 (shortcut_initalized): Ditto.
1128 (create_shortcut_header): Ditto.
1129 (cmp_shortcut_header): Ditto.
1130 (symlink_info::check_shortcut): Ditto. Reorganize as a plain C function.
1131 (symlink_info::check_sysfile): Redefine as a global function using the
1132 same parameter list as `check_shortcut' for clearness.
1133 (symlink_info::check): Change parameter list for calls to
1134 `check_shortcut' and `check_sysfile'.
1135
87e6b098
CV
1136Thu Feb 22 12:04:00 2001 Corinna Vinschen <corinna@vinschen.de>
1137
1138 * fhandler.cc (fhandler_disk_file::open): Use `inner_suffixes' when
1139 resolving real_path.
1140 * path.cc (symlink): Ditto for win32_topath.
1141
10b06c5e
CV
1142Wed Feb 21 22:41:00 2001 Corinna Vinschen <corinna@vinschen.de>
1143
1144 * Makefile.in: Add `-lshell32 -luuid' to link pass for new-cygwin1.dll.
1145 * autoload.cc: Add LoadDLLinitfunc for ole32.dll.
1146 Add LoadDLLfuncEx statements for CoInitialize@4, CoUninitialize@0
1147 and CoCreateInstance@20.
1148 * dir.cc (dir_suffixes): New datastructure.
1149 (readdir): Check for R/O *.lnk files to hide the suffix.
1150 (opendir): Use `dir_suffixes' in path conversion.
1151 (rmdir): Ditto.
1152 * fhandler.cc (fhandler_disk_file::fstat): Add S_IFLNK flag
1153 before calling `get_file_attribute'. Take FILE_ATTRIBUTE_READONLY
1154 into account only if the file is no symlink.
1155 * path.cc (inner_suffixes): New datastructure.
1156 (SYMLINKATTR): Eliminated.
1157 (path_conv::check): Use `inner_suffixes' on inner path components.
1158 (shortcut_header): New global static variable.
1159 (shortcut_initalized): Ditto.
1160 (create_shortcut_header): New function.
1161 (cmp_shortcut_header): Ditto.
1162 (symlink): Create symlinks by creating windows shortcuts. Preserve
1163 the old code.
1164 (symlink_info::check_shortcut): New method.
1165 (symlink_info::check_sysfile): Ditto.
1166 (symlink_info::check): Check for shortcuts. Move code reading
1167 old system attribute symlinks into symlink_info::check_sysfile().
1168 (chdir): Use `dir_suffixes' in path conversion.
1169 * security.cc (get_file_attribute): Check for S_IFLNK flag.
1170 Force 0777 permissions then.
1171 * spawn.cc (std_suffixes): Add ".lnk" suffix.
1172 * syscalls.cc (_unlink): Use `inner_suffixes' in path conversion.
1173 Check for shortcut symlinks to eliminate R/O attribute before
1174 calling DeleteFile().
1175 (stat_suffixes): Add ".lnk" suffix.
1176 (stat_worker): Force 0777 permissions if file is a symlink.
1177
0917ed59
ED
11782001-02-21 Egor Duda <deo@logos-m.ru>
1179
1180 * sigproc.cc (getsem): Make semaphore always non-inheritable.
1181
441d7aee
CF
1182Mon Feb 19 22:25:53 2001 Christopher Faylor <cgf@cygnus.com>
1183
1184 * dcrt0.cc (locale_init): Remove.
1185
f97e7d75
CF
11862001-02-15 Kazuhiro Fujieda <fujieda@jaist.ac.jp>
1187
1188 * cygwin.din: Export rand48 functions.
1189 * thread.cc (MTinterface::Init): Remove the initialization of
1190 `reent_data'.
1191 * dcrt0.cc: Add the initalizer to the declaration of `reent_data'.
1192 * include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR to 35.
1193
fc68bf34
ED
11942001-02-16 Egor Duda <deo@logos-m.ru>
1195
1196 * signal.cc (signal): Prohibit setting handlers for SIGKILL and
1197 SIGSTOP
1198 * signal.cc (sigaction): Ditto
1199 * syscalls.cc (_lseek): Return EINVAL on invalid input
1200
ee2c7251
CF
1201Wed Feb 14 14:54:40 2001 Christophe Iasci <chrisiasci@aol.com>
1202
1203 * dlfcn.cc (dlopen): Do not call LoadLibrary with a NULL pointer, when
1204 the library is not found
1205
8f8e7442 12062001-02-14 Egor Duda <deo@logos-m.ru>
efd76e41 1207
8f8e7442
CF
1208 * fhandler_console.cc (fhandler_console::char_command): Ignore unknown
1209 rendition codes in \033[xx;yym control sequences
1210
cde0c2fb
CF
1211Fri Feb 9 23:19:01 2001 Christopher Faylor <cgf@cygnus.com>
1212
1213 * fork.cc (fork_parent): Return EAGAIN when can't record pid.
1214 * pinfo.h (pinfo::remember): Return value of call to proc_subproc.
1215 * sigproc.cc (proc_subproc): Return error if can't record pid.
1216
c41482c7
CF
1217Fri Feb 9 12:17:27 2001 Christopher Faylor <cgf@cygnus.com>
1218
1219 * syscalls.cc (mknod): Add valid parameters.
1220
889109ab
CV
1221Thu Feb 8 22:09:00 2001 Corinna Vinschen <corinna@vinschen.de>
1222
1223 * mmap.cc (mmap): Check for reusing a mapping only on MAP_SHARED
1224 and on MAP_PRIVATE|MAP_ANON in the special case of offset 0.
1225
db49d0b5
CV
1226Thu Feb 8 21:57:00 2001 Corinna Vinschen <corinna@vinschen.de>
1227
1228 * mmap.cc (class list): Add member `hash'.
1229 (list::list): Initialize `hash'.
1230 (list::get_list_by_fd): Use filepath hash value to get the correct
1231 mapping list if it's not an anonymous mapping.
1232 (map::add_list): Initialize `hash' with filepath hash value.
1233 (mmap): Check for reusing a mapping only on MAP_SHARED.
1234
91d385fe
CF
1235Wed Feb 7 18:47:36 2001 Christopher Faylor <cgf@cygnus.com>
1236
1237 * signal.cc (killpg): Correct first argument.
1238
9182099c
CV
1239Wed Feb 7 22:22:00 2001 Corinna Vinschen <corinna@vinschen.de>
1240
1241 * autoload.cc: Add LoadDLLinitfunc for iphlpapi.dll.
1242 Add LoadDLLfuncEx statements for GetIfTable@12 and GetIpAddrTable@12.
1243 * fhandler_socket.cc (fhandler_socket::ioctl): Move variable
1244 definitions to the beginning of the function to allow better debugging.
1245 Add handling for SIOCGIFHWADDR, SIOCGIFMETRIC and SIOCGIFMTU.
1246 * net.cc: Include iphlpapi.h.
1247 (get_2k_ifconf): Rewritten. Uses IP Helper API now.
1248 (get_nt_ifconf): Add handling for SIOCGIFHWADDR, SIOCGIFMETRIC
1249 and SIOCGIFMTU.
1250 (get_95_ifconf): Ditto. Renamed from `get_9x_ifconf'.
1251 (get_ifconf): Name loopback `lo' instead of `lo0' as in Linux.
1252 Add handling for SIOCGIFHWADDR, SIOCGIFMETRIC and SIOCGIFMTU.
1253 Call `get_95_ifconf' only on Windows 95, `get_nt_ifconf' only
1254 on Windows NT < Service Pack 3, `get_2k_ifconf otherwise.
1255 * include/asm/socket.h: Add defines for SIOCGIFHWADDR, SIOCGIFMETRIC
1256 and SIOCGIFMTU.
1257 * include/cygwin/if.h: Add `ifr_hwaddr', `ifr_metric' and `ifr_mtu'.
1258 (struct ifreq): Add `ifru_hwaddr'.
1259
d7ed877b
CV
1260Tue Feb 6 15:04:00 2001 Corinna Vinschen <corinna@vinschen.de>
1261
1262 * syscalls.cc (stat_worker): Add a check for the special case when
1263 a process creates a file using mode 000 using ntsec.
1264
ae9b22c6
CV
1265Mon Feb 5 17:00:00 2001 Corinna Vinschen <corinna@vinschen.de>
1266
1267 * fhandler.cc (fhandler_base::open): Always add GENERIC_READ access
1268 when opening raw disk devices.
1269 * fhandler_floppy.cc (fhandler_dev_floppy::lseek): Implement bytewise
1270 access.
1271 * fhandler_raw.cc (fhandler_dev_raw::open): Always open raw disk device
1272 binary.
1273 (fhandler_dev_raw::raw_write): Don't drop read buffer content when
1274 writing after read.
1275
cada03f9
CV
1276Mon Feb 5 13:30:00 2001 Corinna Vinschen <corinna@vinschen.de>
1277
1278 * mmap.cc (mmap_record::fixup_map): New method to duplicate
1279 the memory protection in a just forked child.
1280 (mmap): Realign gran_len to page boundary only on anonymous
1281 mapping before saving in the mmap_record.
1282 (munmap): Cleanup code.
1283 (msync): Ditto.
1284 (fixup_mmaps_after_fork): Ditto. Call mmap_record::fixup_map now.
1285
47f81092
CF
1286Thu Feb 1 23:08:29 2001 Christopher Faylor <cgf@cygnus.com>
1287
1288 * cygheap.cc (creturn): Correctly calculate cygheap_max.
1289
f8da1507
CF
1290Wed Jan 31 10:04:58 2001 Christopher Faylor <cgf@cygnus.com>
1291
1292 * shared.cc (shared_info::initialize): Reduce size of heap.
1293
83443511
CV
1294Wed Jan 31 13:22:00 2001 Corinna Vinschen <corinna@vinschen.de>
1295
1296 * include/sys/resource.h: Fix typo.
1297
44e6d951
CV
1298Wed Jan 31 13:20:00 2001 Corinna Vinschen <corinna@vinschen.de>
1299
83443511 1300 * include/sys/resource.h: Add RLIMIT_NLIMITS and RLIM_NLIMITS.
44e6d951 1301
4f42df7b
CF
1302Tue Jan 30 18:15:23 2001 Christopher Faylor <cgf@cygnus.com>
1303
1304 * include/cygwin/version.h: Bump version to 1.3.0.
1305
9928a7e1
CV
1306Tue Jan 30 8:55:00 2001 Corinna Vinschen <corinna@vinschen.de>
1307
1308 * pinfo.cc (pinfo::init): Use INVALID_HANDLE_VALUE instead of
1309 explicit cast (HANDLE) 0xffffffff.
1310 * shared.cc (open_shared): Ditto.
1311
747e88d3
CF
1312Mon Jan 29 17:15:22 2001 Bill Hegardt <bill@troyxcd.com>
1313
1314 * fhandler_serial.cc (raw_write): Use local copy of OVERLAPPED
1315 structure instead of shared structure to fix a race condition between
1316 read/write.
1317
68ea0dc2
CV
1318Mon Jan 29 14:30:00 2001 Corinna Vinschen <corinna@vinschen.de>
1319
1320 * mmap.cc (mmap): Remove obsolete check for MAP_SHARED|MAP_ANON as
1321 being invalid.
1322
f977222f
CV
1323Mon Jan 29 10:23:00 2001 Corinna Vinschen <corinna@vinschen.de>
1324
1325 * mmap.cc (mmap_record::find_empty): Fix loop condition.
1326
6a4878cf
CF
1327Sun Jan 28 19:40:40 2001 Christopher Faylor <cgf@cygnus.com>
1328
1329 * syscalls.cc (_link): Make sure that newpath does not exist. Set
1330 errno if it does.
1331
1332Sun Jan 28 19:29:08 2001 Christopher Faylor <cgf@cygnus.com>
1333
1334 * cygheap.cc (init_cheap): Don't specify a load address for the heap.
1335 It doesn't work on #!*& Windows 9x.
1336 (cygheap_init): Move GetUserName to memory_init.
1337 * dcrt0.cc (dll_crt0_1): Call new memory_init functin, eliminate call
1338 to heap_init.
1339 * heap.cc (heap_init): Improve error output.
1340 * heap.h: Correct some declarations.
1341 * shared.cc (mount_table_init): Remove.
1342 (memory_init): Renamed from shared_init. Reorganize to accomodate
1343 strange Windows 9x problems with cygheap/heap interaction.
1344 * shared_info.h: Rename shared_init to memory_init.
1345
ae6c8e4f
CF
1346Sun Jan 28 01:25:33 2001 Christopher Faylor <cgf@cygnus.com>
1347
1348 * include/cygwin/version.h: Bump API version.
1349
9a089f21
CF
1350Sun Jan 28 01:18:22 2001 Christopher Faylor <cgf@cygnus.com>
1351
1352 * cygheap.cc (init_cheap): Move username initialization.
1353 (cygheap_init): Here.
1354 * shared_info.h (mount_info): Add a sys_mount_table_counter field.
1355 (shared_info): Ditto.
1356 * path.cc (mount_info::conv_to_win32_path): Check that our mount table
1357 is in sync with the system mount table and reinitialize it if not.
1358 (mount_info::add_reg_mount): Bump sys_mount_table counters if the
1359 system mount table changes.
1360 (mount_info::del_reg_mount): Ditto.
1361 (mount_info::write_cygdrive_info_to_registry): Ditto.
1362 (mount_info::remove_cygdrive_info_from_registry): Ditto.
1363
2a6fc028
CF
1364Sun Jan 28 00:28:30 2001 Christopher Faylor <cgf@cygnus.com>
1365
1366 Throughout, change 'cygwin_shared.mount' to 'mount_table'.
1367 * child_info.h (child_info): Move shared_h, console_h to cygheap. Add
1368 mount_h.
1369 * cygheap.h (init_cygheap): Add shared_h, console_h.
1370 * cygheap.cc (init_cheap): Initialize heap at a fixed location after
1371 the shared memory regions. Initialize cygheap->user name here.
1372 * dcrt0.cc (dll_crt0_1): Call getpagesize () to initialize constants.
1373 Remove cygheap_init since it is done in shared_init now.
1374 (_dll_crt0): Initialize mount_h, remove shared_h and console_h
1375 initialization.
1376 * fhandler_console.cc (console_shared_h): Eliminate.
1377 (get_tty_stuff): Use cygheap->console_h rather than console_shared_h.
6a4878cf
CF
1378 * heap.cc (heap_init): Use page size constant calculated earlier in
1379 initialization.
2a6fc028
CF
1380 * shared.cc: Eliminate cygwin_shared_h. Add cygwin_mount_h.
1381 (mount_table_init): New function for initializing a user mount table.
6a4878cf
CF
1382 (open_shared_file_map): Use constant for shared memory region.
1383 Initialize cygheap and mount table here.
2a6fc028
CF
1384 (open_shared): Improve debugging output.
1385 (shared_info::initialize): Eliminate call to mount.init.
1386 (shared_terminate): Use cygheap->shared_h. Close cygwin_mount_h.
1387 (open_shared_file_map): Eliminate.
1388 * shared_info.h (mount_info): Add a version field.
6a4878cf
CF
1389 (shared_align_past): New macro for calculating location for shared
1390 memory regions.
2a6fc028 1391 * sigproc.cc (init_child_info): Eliminate shared_h, console_h.
6a4878cf
CF
1392 * spawn.cc (spawn_guts): Pass on cygwin_mount_h iff not a different
1393 user.
2a6fc028
CF
1394 * syscalls.cc (system_info): New global holding system memory defaults.
1395 (getpagesize): Use system_info.
1396 * uinfo.cc (internal_getlogin): Only fill in user name if nonexistent.
1397 * winsup.h: Declare system_info.
1398
6a4878cf
CF
1399 * passwd.cc (read_etc_passwd): Use cygheap->user.name () rather than
1400 retrieving the name again.
2a6fc028 1401
bdfeca60
CF
1402Sat Jan 27 10:18:02 2001 Christopher Faylor <cgf@cygnus.com>
1403
1404 * path.cc (path_conv::check): Detect when path has symlinks.
1405 (symlink_info::check): Remove debugging stuff.
1406 (chdir): Use posix'ized win32 path if cd'ed to a path using symlinks.
1407
206a8d88
CF
1408Fri Jan 26 21:20:28 2001 Christopher Faylor <cgf@cygnus.com>
1409
1410 * exceptions.cc (sigreturn): Call any pending signals prior to
1411 resetting the signal mask so that stacked signals behave correctly.
1412 (sigdelayed): Avoid a race where a signal could end up calling an
1413 incorrect signal handler if two signals come in close together.
1414
174f1a39
CV
1415Tue Jan 23 21:56:00 2001 Corinna Vinschen <corinna@vinschen.de>
1416
1417 * mmap.cc (fhandler_disk_file::mmap): Call CreateFileMapping with
1418 len != 0 only when performing an anonymous mapping.
1419
4c7b8250
CF
1420Mon Jan 22 15:35:28 2001 Christopher Faylor <cgf@cygnus.com>
1421
1422 * path.h: Add a new constant.
1423 * syscalls.cc (_read): Oscillate errno check.
1424
c65a3183
CF
1425Mon Jan 22 15:27:12 2001 Christopher Faylor <cgf@cygnus.com>
1426
1427 * include/cygwin/version.h: Bump API to reflect setlogmask.
1428
29c39fe3
CF
1429Sun Jan 21 22:40:25 2001 Jason Tishler <jt@dothill.com>
1430
1431 * cygwin.din: Add export for setlogmask().
1432 * syslog.cc (setlogmask): New function.
1433
c807d355
CV
1434Thu Jan 18 10:27:00 2001 Corinna Vinschen <corinna@vinschen.de>
1435
1436 * resource.cc (setrlimit): Support RLIMIT_NOFILE.
1437
4e2a97b2
CF
1438Wed Jan 17 23:23:12 2001 Christopher Faylor <cgf@cygnus.com>
1439
1440 * syscalls.cc (setdtablesize): Call with amount to increment not total
1441 amount. Return success or failure error code.
1442
a7cde2b9
CF
1443Wed Jan 17 09:47:13 2001 Christopher Faylor <cgf@cygnus.com>
1444
1445 * autoload.cc (LoadDLLinitfunc): Remove debugging statement.
1446
1447 * exceptions.cc (sig_handle_tty_stop): Move setting of PID_STOPPED to
1448 earlier in interrupt.
1449 ((interrupt_setup): i.e., here.
1450 (sig_handle): Don't queue multiple SIGSTOPS.
1451 * fhandler.h (bg_check_types): Enumerate return value of bg_check for
1452 clarity.
1453 * signal.cc (kill_pgrp): Minor cleanup.
1454 * fhandler_termios.cc (fhandler_termios::bg_check): Use enumerated type
1455 for function return. Don't raise signal if a signal is already queued.
1456 * fhandler_console.cc (fhandler_console::read): Use enumerated return
1457 type for bg_check.
1458 * select.cc: Ditto, throughout.
1459 * read.cc: Ditto, throughout.
1460 * termios.cc: Ditto, throughout.
1461 (_read): YA interrupt detect simplification.
1462 * wait.cc (wait4): Ditto.
1463
cb503978
CV
1464Wed Jan 17 10:56:00 2001 Corinna Vinschen <corinna@vinschen.de>
1465
1466 * cygheap.cc (cygheap_user::~cygheap_user): Temporarily
1467 disable free'ing memory.
1468
9fedfd57
CV
1469Tue Jan 16 18:01:00 2001 Corinna Vinschen <corinna@vinschen.de>
1470
1471 * mmap.cc (mmap): Initialize fh to avoid compiler warnings.
1472
9470a80c
CF
1473Mon Jan 15 21:07:00 2001 Christopher Faylor <cgf@cygnus.com>
1474
1475 * wait.cc (wait4): Rename variable for consistency. Allow restartable
1476 signal behavior.
1477
9334c89c
CV
1478Mon Jan 15 23:15:00 2001 Corinna Vinschen <corinna@vinschen.de>
1479
1480 * mmap.cc (mmap): Add more parameter checking. Change error output
1481 in case of EINVAL. Treat mmapping /dev/zero like MAP_ANONYMOUS.
1482
c6dd43f2
CV
1483Mon Jan 15 20:34:00 2001 Corinna Vinschen <corinna@vinschen.de>
1484
1485 * mmap.cc: include <unistd.h>. Define some bit operations for
1486 the new page map.
1487 (mmap_record): Change type of base_address_ to caddr_t.
1488 Add map_map_ member. Add several methods to manipulate map_map_.
1489 (mmap_record::alloc_map): New method.
1490 (mmap_record::free_map): Ditto.
1491 (mmap_record::find_empty): Ditto.
1492 (mmap_record::map_map): Ditto.
1493 (mmap_record::unmap_map): Ditto.
1494 (list::add_record): Change return type to `mmap_record *'.
1495 Allocate page map.
1496 (list::match): New method.
1497 (mmap): Partly rewritten to take care for the new page map. Add some
1498 parameter checking.
1499 (munmap): Ditto.
1500
66097f06
CV
1501Mon Jan 15 13:50:00 2001 Corinna Vinschen <corinna@vinschen.de>
1502
1503 * heap.cc (heap_init): Fix extern declaration of getpagesize.
1504 * syscalls.cc (getpagesize): Fix another typo.
1505
dc3651b6
CV
1506Mon Jan 15 12:48:00 2001 Corinna Vinschen <corinna@vinschen.de>
1507
1508 * syscalls.cc (getpagesize): Save pagesize in global variable to
1509 avoid calling GetSystemInfo too often.
1510 * heap.cc (getpagesize): Eliminate.
1511 (heap_init): Use getpagesize function from syscalls.cc.
1512
4cf2c0e0
CV
1513Mon Jan 15 11:56:00 2001 Corinna Vinschen <corinna@vinschen.de>
1514
1515 * sysconf.cc (sysconf): return `getpagesize ()' on _SC_PAGESIZE
1516 request to avoid implementing the same twice.
1517
a3ec080b
CF
1518Sun Jan 14 14:07:50 2001 Christopher Faylor <cgf@cygnus.com>
1519
1520 * syscalls.cc (_read): Use more lightweight method for determining if
1521 read has been interrupted by a signal.
1522
c3d62298
CF
1523Fri Jan 12 00:35:15 2001 Christopher Faylor <cgf@cygnus.com>
1524
1525 * debug.h: Add regparm attributes to some functions.
1526
1527 * signal.cc (sigaction): Don't treat SIGCONT specially.
1528
6a4878cf
CF
1529 * exceptions.cc (interrupt_setup): Save sa_flags of interrupted signal
1530 for later use.
c3d62298
CF
1531 (sig_handler): Default any stopping signal to SIGSTOP.
1532 (call_signal_handler): New function.
1533 (sigdelayed0): New function.
6a4878cf
CF
1534 * sigproc.cc (sigproc_init): Initialize SIGSTOP sigaction for special
1535 behavior.
c3d62298
CF
1536 * sigproc.h: Define call_signal_handler.
1537 * syscalls.cc (_read): Allow restartable signal behavior.
1538
c4efddf6
CV
1539Thu Jan 11 13:17:00 2001 Corinna Vinschen <corinna@vinschen.de>
1540
1541 * fhandler.h (fhandler_base): New method `fixup_mmap_after_fork'.
1542 (fhandler_disk_file: Ditto.
1543 (fhandler_dev_mem): Ditto.
1544 * fhandler_mem.cc (fhandler_dev_mem::open): Set OBJ_INHERIT attribute
1545 for device\physicalmemory handle.
1546 (fhandler_dev_mem::mmap): Ditto.
6a4878cf
CF
1547 * fhandler_mem.cc (fhandler_dev_mem::fixup_mmap_after_fork): New
1548 method.
1549 * mmap.cc (mmap_record): Add private `fdesc_' member. Change
1550 constructor accordingly.
c4efddf6
CV
1551 (get_fd): New method.
1552 (mmap): Use new mmap_record constructor.
1553 (fhandler_base::fixup_mmap_after_fork): New method.
1554 (fhandler_disk_file::fixup_mmap_after_fork): Ditto.
6a4878cf 1555 (fixup_mmaps_after_fork): Call `fixup_mmap_after_fork' of appropriate
c4efddf6
CV
1556 fhandler class.
1557
7416e1d2
CF
1558Wed Jan 10 22:08:30 2001 Kazuhiro Fujieda <fujieda@jaist.ac.jp>
1559
1560 * sigproc.cc (wait_sig): Allow SIGCONT when stopped.
1561
55ae1dff
CV
1562Tue Jan 9 16:55:00 2001 Corinna Vinschen <corinna@vinschen.de>
1563
1564