]> sourceware.org Git - newlib-cygwin.git/blame - winsup/cygwin/ChangeLog
Add iWMMXt support
[newlib-cygwin.git] / winsup / cygwin / ChangeLog
CommitLineData
9306ba2e
TP
12003-03-23 Thomas Pfaff <tpfaff@gmx.net>
2
3 * thread.h (class List): Move inline code inside class
4 declaration.
5 (List::forEach): Change callback parameter to template class
b2ee9a55 6 member function pointer.
9306ba2e
TP
7 (pthread_keys::fixup_before_fork): Change to inline. Use
8 List::forEach to fixup keys.
9 (pthread_keys::fixup_after_fork): Ditto.
10 (pthread_keys::runAllDestructors): Ditto.
11 (pthread_key::saveAKey): Remove.
12 (pthread_key::restoreAKey): Ditto.
13 (pthread_key::destroyAKey): Ditto.
14 (pthread_key::run_destructor): Rename to runDestructor.
15 (pthread_mutex::fixup_after_fork): Change to inline. Use
16 List::forEach to fixup mutexes after a fork.
17 (pthread_mutex::FixupAfterFork): New method.
18 (pthread_mutex::mutexes): New member.
19 (pthread_cond::fixup_after_fork): Change to inline. Use
20 List::forEach to fixup conds after a fork.
21 (pthread_cond::FixupAfterFork): New method.
22 (pthread_cond::conds): New member.
23 (pthread_rwlock::fixup_after_fork): Change to inline. Use
24 List::forEach to fixup rwlocks after a fork.
25 (pthread_rwlock::FixupAfterFork): New method.
26 (pthread_rwlock::rwlocks): New member.
27 (semaphore::fixup_after_fork): Change to inline. Use
28 List::forEach to fixup mutexes after a fork.
29 (semaphore::FixupAfterFork): New method.
30 (semaphore::semaphores): New member.
31 (MTinterface::mutexs): Remove.
32 (MTinterface::conds): Ditto.
33 (MTinterface::rwlocks): Ditto.
34 (MTinterface::semaphores): Ditto.
35 (pthread_equal): Add extern "C".
36 (pthread_mutex_lock): Ditto.
37
38 * thread.cc (MTinterface::fixup_after_fork): Change
39 fixup_after_fork calls for pthread objects.
40 (semaphore::conds): Instantiate.
41 (pthread_cond::pthread_cond): Use List::Insert rather than
42 custom list code.
43 (pthread_cond::~pthread_cond): Use List::Remove rather than
44 custom list code.
45 (pthread_cond::fixup_after_fork): Rename to FixupAfterFork.
46 (pthread_rwlock::rwlocks): Instantiate.
47 (pthread_rwlock::pthread_crwlock): Use List::Insert rather than
48 custom list code.
49 (pthread_rwlock::~pthread_rwlock): Use List::Remove rather than
50 custom list code.
51 (pthread_rwlock::fixup_after_fork): Rename to FixupAfterFork.
52 (pthread_key::saveAKey): Remove.
53 (pthread_key::fixup_before_fork): Ditto.
54 (pthread_key::restoreAKey): Ditto.
55 (pthread_key::fixup_after_fork): Ditto.
56 (pthread_key::destroyAKey): Ditto.
57 (pthread_key::runAllDestructors): Ditto.
58 (pthread_key::run_destructor): Rename to runDestructor.
59 (pthread_mutex::mutexes): Instantiate.
60 (pthread_mutex::pthread_mutex): Use List::Insert rather than
61 custom list code.
62 (pthread_mutex::~pthread_mutex): Use List::Remove rather than
63 custom list code.
64 (pthread_mutex::fixup_after_fork): Rename to FixupAfterFork.
65 (semaphore::conds): Instantiate.
66 (semaphore::semaphore): Use List::Insert rather than custom list
67 code.
68 (semaphores::~semaphore): Use List::Remove rather than custom
69 list code.
70 (semaphore::fixup_after_fork): Rename to FixupAfterFork.
71
ff3ef36d
CF
722003-03-22 Christopher Faylor <cgf@redhat.com>
73
74 * pipe.cc (fhandler_pipe::dup): Don't dup input_handle if it doesn't
75 exist.
76
ca04f61f
CF
772003-03-22 Christopher Faylor <cgf@redhat.com>
78
79 * syscalls.cc (unlink): Be more defensive when SetFileAttributes is
80 called. Fix typo in debugging output.
81
89e7a1ce
CF
822003-03-21 Christopher Faylor <cgf@redhat.com>
83
84 * fork.cc: Conditionalize use of slow_pid_reuse throughout. It's not
85 necessary for newer versions of bash.
86
fa85038b
CV
872003-03-20 Corinna Vinschen <corinna@vinschen.de>
88
89 * fhandler_socket.cc (fhandler_socket::sendto): Restrict EPIPE and
90 SIGPIPE handling to connection oriented sockets. Add comment.
91
4da34970
CF
922003-03-19 Christopher Faylor <cgf@redhat.com>
93
94 * sigproc.h (signal_fixup_after_exec): Eliminate argument in declaration.
95 * exceptions.cc (signal_fixup_after_exec): Eliminate argument in
96 definition. Don't reset signal handlers after spawm. Just treat like
97 fork/exec.
98 * dcrt0.cc (dll_crt0_1): Don't pass PROC_SPAWN argument to
99 signal_fixup_after_exec.
100 * syscalls.cc (unlink): Don't change attributes of file if not readonly/system.
101 Ditto for resetting of arguments.
102
036ac6b3
CV
1032003-03-19 Corinna Vinschen <corinna@vinschen.de>
104
105 * glob.c: Eliminate __INSIDE_CYGWIN__ preprocessor conditionals
106 throughout.
107
b1897d27
CV
1082003-03-19 Corinna Vinschen <corinna@vinschen.de>
109
110 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Fix
111 wrong usage of S_IFDIR.
112 * security.cc (get_attribute_from_acl): Ditto.
113 (get_file_attribute): Fix wrong usage of S_IFLNK.
114 (get_object_attribute): Ditto.
115 (alloc_sd): Fix wrong usage of S_IFDIR.
116 * syscalls.cc (chmod): Allow chmod'ing of socket files.
117
c16d0946
CV
1182003-03-19 Corinna Vinschen <corinna@vinschen.de>
119
120 * include/cygwin/version.h (CYGWIN_VERSION_CHECK_FOR_USING_BIG_TYPES):
121 Define.
122 * glob.c (g_lstat): Use CYGWIN_VERSION_CHECK_FOR_USING_BIG_TYPES
123 instead of numerical constants.
124 (g_stat): Ditto.
125
6a80a133
TP
1262003-03-18 Thomas Pfaff <tpfaff@gmx.net>
127
128 * pthread.cc (pthread_attr_init): Remove
129 (pthread_attr_destroy): Ditto.
130 (pthread_attr_setdetachstate): Ditto.
131 (pthread_attr_getdetachstate): Ditto.
132 (pthread_attr_setstacksize): Ditto.
133 (pthread_attr_getstacksize): Ditto.
134 (pthread_attr_setinheritsched): Ditto.
135 (pthread_attr_getinheritsched): Ditto.
136 (pthread_attr_setschedparam): Ditto.
137 (pthread_attr_getschedparam): Ditto.
138 (pthread_attr_setschedpolicy): Ditto.
139 (pthread_attr_getschedpolicy): Ditto.
140 (pthread_attr_setscope): Ditto.
141 (pthread_attr_getscope): Ditto.
142 (pthread_attr_setstackaddr): Ditto.
143 (pthread_attr_getstackaddr): Ditto.
144 (pthread_key_create): Ditto.
145 (pthread_key_delete): Ditto.
146 (pthread_setspecific): Ditto.
147 (pthread_getspecific): Ditto.
148 (pthread_kill): Ditto.
149 (pthread_sigmask): Ditto.
150 (pthread_equal): Ditto.
151 (pthread_mutex_lock): Ditto.
152 (pthread_mutex_trylock): Ditto.
153 (pthread_mutex_unlock): Ditto.
154 (pthread_mutex_destroy): Ditto.
155 (pthread_mutex_setprioceiling): Ditto.
156 (pthread_mutex_getprioceiling): Ditto.
157 (pthread_mutexattr_destroy): Ditto.
158 (pthread_mutexattr_getprioceiling): Ditto.
159 (pthread_mutexattr_getprotocol): Ditto.
160 (pthread_mutexattr_getpshared): Ditto.
161 (pthread_mutexattr_gettype): Ditto.
162 (pthread_mutexattr_init): Ditto.
163 (pthread_mutexattr_setprioceiling): Ditto.
164 (pthread_mutexattr_setprotocol): Ditto.
165 (pthread_mutexattr_setpshared): Ditto.
166 (pthread_mutexattr_settype): Ditto.
167 (pthread_cond_destroy): Ditto.
168 (pthread_cond_signal): Ditto.
169 (pthread_cond_broadcast): Ditto.
170 (pthread_condattr_init): Ditto.
171 (pthread_condattr_destroy): Ditto.
172 (pthread_condattr_getpshared): Ditto.
173 (pthread_condattr_setpshared): Ditto.
174 (pthread_rwlock_destroy): Ditto.
175 (pthread_rwlock_rdlock): Ditto.
176 (pthread_rwlock_tryrdlock): Ditto.
177 (pthread_rwlock_wrlock): Ditto.
178 (pthread_rwlock_trywrlock): Ditto.
179 (pthread_rwlock_unlock): Ditto.
180 (pthread_rwlockattr_init): Ditto.
181 (pthread_rwlockattr_getpshared): Ditto.
182 (pthread_rwlockattr_setpshared): Ditto.
183 (pthread_rwlockattr_destroy): Ditto.
184 (pthread_getconcurrency): Ditto.
185 (pthread_setconcurrency): Ditto.
186 (pthread_getschedparam): Ditto.
187 (pthread_setschedparam): Ditto.
188
189 * thread.h (__pthread_attr_init): Remove prototype.
190 (__pthread_attr_destroy): Ditto.
191 (__pthread_attr_setdetachstate): Ditto.
192 (__pthread_attr_getdetachstate): Ditto.
193 (__pthread_attr_setstacksize): Ditto.
194 (__pthread_attr_getstacksize): Ditto.
195 (__pthread_attr_setinheritsched): Ditto.
196 (__pthread_attr_getinheritsched): Ditto.
197 (__pthread_attr_setschedparam): Ditto.
198 (__pthread_attr_getschedparam): Ditto.
199 (__pthread_attr_setschedpolicy): Ditto.
200 (__pthread_attr_getschedpolicy): Ditto.
201 (__pthread_attr_setscope): Ditto.
202 (__pthread_attr_getscope): Ditto.
203 (__pthread_attr_setstackaddr): Ditto.
204 (__pthread_attr_getstackaddr): Ditto.
205 (__pthread_key_create): Ditto.
206 (__pthread_key_delete): Ditto.
207 (__pthread_setspecific): Ditto.
208 (__pthread_getspecific): Ditto.
209 (__pthread_kill): Ditto.
210 (__pthread_sigmask): Ditto.
211 (__pthread_equal): Ditto.
212 (__pthread_mutex_lock): Ditto.
213 (__pthread_mutex_trylock): Ditto.
214 (__pthread_mutex_unlock): Ditto.
215 (__pthread_mutex_destroy): Ditto.
216 (__pthread_mutex_setprioceiling): Ditto.
217 (__pthread_mutex_getprioceiling): Ditto.
218 (__pthread_mutexattr_destroy): Ditto.
219 (__pthread_mutexattr_getprioceiling): Ditto.
220 (__pthread_mutexattr_getprotocol): Ditto.
221 (__pthread_mutexattr_getpshared): Ditto.
222 (__pthread_mutexattr_gettype): Ditto.
223 (__pthread_mutexattr_init): Ditto.
224 (__pthread_mutexattr_setprioceiling): Ditto.
225 (__pthread_mutexattr_setprotocol): Ditto.
226 (__pthread_mutexattr_setpshared): Ditto.
227 (__pthread_mutexattr_settype): Ditto.
228 (__pthread_cond_destroy): Ditto.
229 (__pthread_cond_signal): Ditto.
230 (__pthread_cond_broadcast): Ditto.
231 (__pthread_condattr_init): Ditto.
232 (__pthread_condattr_destroy): Ditto.
233 (__pthread_condattr_getpshared): Ditto.
234 (__pthread_condattr_setpshared): Ditto.
235 (__pthread_rwlock_destroy): Ditto.
236 (__pthread_rwlock_rdlock): Ditto.
237 (__pthread_rwlock_tryrdlock): Ditto.
238 (__pthread_rwlock_wrlock): Ditto.
239 (__pthread_rwlock_trywrlock): Ditto.
240 (__pthread_rwlock_unlock): Ditto.
241 (__pthread_rwlockattr_init): Ditto.
242 (__pthread_rwlockattr_getpshared): Ditto.
243 (__pthread_rwlockattr_setpshared): Ditto.
244 (__pthread_rwlockattr_destroy): Ditto.
245 (__pthread_getconcurrency): Ditto.
246 (__pthread_setconcurrency): Ditto.
247 (__pthread_getschedparam): Ditto.
248 (__pthread_setschedparam): Ditto.
249
250 * thread.cc: Rename __pthread_equal to pthread_equal throughout.
251 Change pthread_self parameter appropriate.
252 (__pthread_attr_init): Remove __ prefix. Change to extern "C".
253 (__pthread_attr_destroy): Ditto.
254 (__pthread_attr_setdetachstate): Ditto.
255 (__pthread_attr_getdetachstate): Ditto.
256 (__pthread_attr_setstacksize): Ditto.
257 (__pthread_attr_getstacksize): Ditto.
258 (__pthread_attr_setinheritsched): Ditto.
259 (__pthread_attr_getinheritsched): Ditto.
260 (__pthread_attr_setschedparam): Ditto.
261 (__pthread_attr_getschedparam): Ditto.
262 (__pthread_attr_setschedpolicy): Ditto.
263 (__pthread_attr_getschedpolicy): Ditto.
264 (__pthread_attr_setscope): Ditto.
265 (__pthread_attr_getscope): Ditto.
266 (__pthread_attr_setstackaddr): Ditto.
267 (__pthread_attr_getstackaddr): Ditto.
268 (__pthread_key_create): Ditto.
269 (__pthread_key_delete): Ditto.
270 (__pthread_setspecific): Ditto.
271 (__pthread_getspecific): Ditto.
272 (__pthread_kill): Ditto.
273 (__pthread_sigmask): Ditto.
274 (__pthread_equal): Ditto.
275 (__pthread_mutex_lock): Ditto.
276 (__pthread_mutex_trylock): Ditto.
277 (__pthread_mutex_unlock): Ditto.
278 (__pthread_mutex_destroy): Ditto.
279 (__pthread_mutex_setprioceiling): Ditto.
280 (__pthread_mutex_getprioceiling): Ditto.
281 (__pthread_mutexattr_destroy): Ditto.
282 (__pthread_mutexattr_getprioceiling): Ditto.
283 (__pthread_mutexattr_getprotocol): Ditto.
284 (__pthread_mutexattr_getpshared): Ditto.
285 (__pthread_mutexattr_gettype): Ditto.
286 (__pthread_mutexattr_init): Ditto.
287 (__pthread_mutexattr_setprioceiling): Ditto.
288 (__pthread_mutexattr_setprotocol): Ditto.
289 (__pthread_mutexattr_setpshared): Ditto.
290 (__pthread_mutexattr_settype): Ditto.
291 (__pthread_cond_destroy): Ditto.
292 (__pthread_cond_signal): Ditto.
293 (__pthread_cond_broadcast): Ditto.
294 (__pthread_condattr_init): Ditto.
295 (__pthread_condattr_destroy): Ditto.
296 (__pthread_condattr_getpshared): Ditto.
297 (__pthread_condattr_setpshared): Ditto.
298 (__pthread_rwlock_destroy): Ditto.
299 (__pthread_rwlock_rdlock): Ditto.
300 (__pthread_rwlock_tryrdlock): Ditto.
301 (__pthread_rwlock_wrlock): Ditto.
302 (__pthread_rwlock_trywrlock): Ditto.
303 (__pthread_rwlock_unlock): Ditto.
304 (__pthread_rwlockattr_init): Ditto.
305 (__pthread_rwlockattr_getpshared): Ditto.
306 (__pthread_rwlockattr_setpshared): Ditto.
307 (__pthread_rwlockattr_destroy): Ditto.
308 (__pthread_getconcurrency): Ditto.
309 (__pthread_setconcurrency): Ditto.
310 (__pthread_getschedparam): Ditto.
311 (__pthread_setschedparam): Ditto.
312
00d296a3
TP
3132003-03-18 Thomas Pfaff <tpfaff@gmx.net>
314
315 * cygwin.din: Add pthread_rwlock_destroy, pthread_rwlock_init,
316 pthread_rwlock_rdlock, pthread_rwlock_tryrdlock,
317 pthread_rwlock_wrlock, pthread_rwlock_trywrlock,
318 pthread_rwlock_unlock, pthread_rwlockattr_init,
319 pthread_rwlockattr_getpshared, pthread_rwlockattr_setpshared,
320 and pthread_rwlockattr_destroy.
321 * include/cygwin/version.h: Bump API minor number.
322 * include/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Define a
323 reasonable value.
324 Add prototypes for pthread_rwlock_destroy, pthread_rwlock_init,
325 pthread_rwlock_rdlock, pthread_rwlock_tryrdlock,
326 pthread_rwlock_wrlock, pthread_rwlock_trywrlock,
327 pthread_rwlock_unlock, pthread_rwlockattr_init,
328 pthread_rwlockattr_getpshared, pthread_rwlockattr_setpshared,
329 and pthread_rwlockattr_destroy.
330 * thread.h (PTHREAD_ONCE_MAGIC): Remove superflous semicolon.
331 (PTHREAD_RWLOCK_MAGIC): New define.
332 (PTHREAD_RWLOCKATTR_MAGIC): Ditto.
333 (pthread_rwlockattr): New class.
334 (pthread_rwlock): Ditto.
335 (MTinterface::rwlocks): New member.
336 (MTinterface::MTinterface): Initialize rwlocks.
337 Add prototypes for __pthread_rwlock_destroy,
338 __pthread_rwlock_wrlock, __pthread_rwlock_trywrlock,
339 __pthread_rwlock_unlock, __pthread_rwlockattr_init,
340 __pthread_rwlockattr_getpshared, __pthread_rwlockattr_setpshared,
341 and __pthread_rwlockattr_destroy.
342 * thread.cc (MTinterface::Init): Initialize rwlock internal mutex.
343 (MTinterface::fixup_after_fork): Fixup rwlocks after fork.
344 (pthread_rwlockattr::isGoodObject): Implement.
345 (pthread_rwlockattr::pthread_rwlockattr): Ditto.
346 (pthread_rwlockattr::~pthread_rwlockattr): Ditto.
347 (pthread_rwlock::initMutex): Ditto.
348 (pthread_rwlock::pthread_rwlock): Ditto.
349 (pthread_rwlock::~pthread_rwlock): Ditto.
350 (pthread_rwlock::RdLock): Ditto.
351 (pthread_rwlock::TryRdLock): Ditto.
352 (pthread_rwlock::WrLock): Ditto.
353 (pthread_rwlock::TryWrLock): Ditto.
354 (pthread_rwlock::UnLock): Ditto.
355 (pthread_rwlock::addReader): Ditto.
356 (pthread_rwlock::removeReader): Ditto.
357 (pthread_rwlock::lookupReader): Ditto.
358 (pthread_rwlock::RdLockCleanup): Ditto.
359 (pthread_rwlock::WrLockCleanup): Ditto.
360 (pthread_rwlock::fixup_after_fork): Ditto.
361 (pthread_rwlock::isGoodObject): Ditto.
362 (pthread_rwlock::isGoodInitializer): Ditto.
363 (pthread_rwlock::isGoodInitializerOrObject): Ditto.
364 (pthread_rwlock::isGoodInitializerOrBadObject): Ditto.
365 (__pthread_rwlock_destroy): Ditto.
366 (pthread_rwlock::init): Ditto.
367 (__pthread_rwlock_rdlock): Ditto.
368 (__pthread_rwlock_tryrdlock): Ditto.
369 (__pthread_rwlock_wrlock): Ditto.
370 (__pthread_rwlock_trywrlock): Ditto.
371
f592b05d
TP
3722003-03-18 Thomas Pfaff <tpfaff@gmx.net>
373
374 * thread.h (pthread_cond::ExitingWait): Remove.
375 (pthread_cond::mutex): Ditto.
376 (pthread_cond::cond_access): Ditto.
377 (pthread_cond::win32_obj_id): Ditto.
378 (pthread_cond::TimedWait): Ditto.
379 (pthread_cond::BroadCast): Ditto.
380 (pthread_cond::Signal): Ditto.
381 (pthread_cond::waiting): Change type to unsigned long.
382 (pthread_cond::pending): New member.
383 (pthread_cond::semWait): Ditto.
384 (pthread_cond::mtxIn): Ditto.
385 (pthread_cond::mtxOut): Ditto.
386 (pthread_cond::mtxCond): Ditto.
387 (pthread_cond::UnBlock): New method.
388 (pthread_cond::Wait): Ditto.
389 * thread.cc: Update list of cancellation points.
390 (pthread_cond::pthread_cond): Rewrite.
391 (pthread_cond::~pthread_cond): Ditto.
392 (pthread_cond::TimedWait): Remove.
393 (pthread_cond::BroadCast): Ditto.
394 (pthread_cond::Signal): Ditto.
395 (pthread_cond::UnBlock): Implement.
396 (pthread_cond::Wait): Ditto.
397 (pthread_cond::fixup_after_fork): Rewrite.
398 (pthread_mutex::fixup_after_fork): Remove DETECT_BAD_APP
399 conditional.
400 (__pthread_cond_broadcast): Just return 0 if the condition is
401 not initialized. Call pthread_cond::UnBlock to release blocked
402 threads.
403 (__pthread_cond_signal): Ditto.
404 (__pthread_cond__dowait): Rewrite.
405 (pthread_cond_timedwait): Add pthread_testcancel call. Fix
406 waitlength calculation.
407 (pthread_cond_wait): Add pthread_testcancel call.
408
2ff03dc2
TP
4092003-03-18 Thomas Pfaff <tpfaff@gmx.net>
410
411 * include/pthread.h (PTHREAD_MUTEX_NORMAL): New define.
412 * thread.cc: Remove errno.h include.
413 (pthread::precreate): Change internal mutex type to normal.
414 (pthread_mutex::canBeUnlocked): Implement.
415 (pthread_mutex::pthread_mutex): Initialize lock_counter with 0.
416 (pthread_mutex::Lock): Rename to _Lock. Add self parameter.
417 Change lock_counter logic. Update SetOwner call.
418 (pthread_mutex::TryLock): Rename to _TryLock. Add self parameter.
419 Change lock_counter logic. Update SetOwner call.
420 (pthread_mutex::UnLock): Rename to _UnLock. Add self parameter.
421 Change lock_counter logic.
422 (pthread_mutex::Destroy): Rename to _Destroy. Update TryLock call.
423 (pthread_mutex::SetOwner): Move to thread.h as inline.
424 (pthread_mutex::LockRecursive): Ditto.
425 (pthread_mutex::fixup_after_fork): Change lock_counter logic.
426 (__pthread_mutexattr_settype): Add PTHREAD_MUTEX_NORMAL to valid
427 types check.
428 * thread.h: Include errno.h and limits.h.
429 (MUTEX_LOCK_COUNTER_INITIAL): Remove.
430 (MUTEX_OWNER_ANONYMOUS): New define.
431 (pthread_mutex::canBeUnlocked): New static method.
432 (pthread_mutex::lock_counter): Change type to unsigned long.
433 (pthread_mutex::GetPthreadSelf): New method.
434 (pthread_mutex::Lock): Call _Lock with pthread_self pointer.
435 (pthread_mutex::TryLock): Call _TryLock with pthread_self pointer.
436 (pthread_mutex::UnLock): Call _UnLock with pthread_self pointer.
437 (pthread_mutex::Destroy): Call _Destroy with pthread_self pointer.
438 (pthread_mutex::SetOwner): Moved from thread.cc as inline.
439 (pthread_mutex::LockRecursive): Ditto.
440 (pthread_mutex::_Lock): New method.
441 (pthread_mutex::_TryLock): New method.
442 (pthread_mutex::_UnLock): New method.
443 (pthread_mutex::_Destroy): New method.
444
dcd350f0
CV
4452003-03-18 Christopher January <chris@atomice.net>
446
447 * fhandler_proc.cc (format_proc_cpuinfo): Use IsProcessorFeaturePresent
448 only on Windows NT. Read CPU Mhz value only on NT. Revert previous
449 change so cpuid instruction is called even on non-NT systems.
450
c51dc9c2
CV
4512003-03-17 Corinna Vinschen <corinna@vinschen.de>
452
453 * glob.c (g_lstat): Change API minor test to match API minor number
454 change in previous patch.
455 (g_stat): Ditto.
456
f194ba1f
CF
4572003-03-17 Christopher Faylor <cgf@redhat.com>
458
459 * include/cygwin/version.h: Reorganize last two api versions so that
460 btowc and trunc exports show up before previous bump since there has
461 been no exported version of the DLL with the 64 bit changes yet but
462 1.3.22 will have the btowc and trunc.
463
3543669f
CF
4642003-03-17 Christopher Faylor <cgf@redhat.com>
465
466 * cygwin.din: Export btowc, trunc.
467 * include/cygwin/version.h: Reflect new exports.
468 * syscalls.cc (_stat): Rename to stat to avoid newlib wrapper.
469 * syscalls.cc (_fstat): Ditto.
470
4712003-03-16 Christopher Faylor <cgf@redhat.com>
472
473 * fhandler_console.cc (fhandler_console::close): Correct check for
474 current tty. Add debugging output when console is freed.
475 (set_console_state_for_spawn): Add debugging output.
476 * fhandler_tty.cc (fhandler_tty_slave::open): Don't decrement console
477 open flag when vforking.
478 * sigproc.cc (sigproc_terminate): Fix debugging output.
479 * spawn.cc (handle): Eliminate second argument.
480 (spawn_guts): Reflect elimination of argument change to handle.
481 * syscalls.cc (setsid): Add debugging output when console is freed.
482
4832003-03-14 Christopher Faylor <cgf@redhat.com>
484
485 * syscalls.cc (rename): Revert assumption that DELETE_ON_CLOSE works on
486 Win9x.
487
41ffdfa5
CF
4882003-03-13 Christopher Faylor <cgf@redhat.com>
489
490 * include/cygwin/version.h: Bump DLL minor number to 23.
491
5b186cd9
CV
4922003-03-13 Corinna Vinschen <corinna@vinschen.de>
493
494 * autoload.cc (IsProcessorFeaturePresent): Add.
495 * fhandler_proc.cc (format_proc_cpuinfo): Add case for 9x systems.
496
c58555c7
CV
4972003-03-13 Corinna Vinschen <corinna@vinschen.de>
498
499 * fhandler_proc.cc (format_proc_cpuinfo): Fix vendor id in cpuid case.
500
49a0d53c
CV
5012003-03-13 Corinna Vinschen <corinna@vinschen.de>
502
503 * net.cc (cygwin_rcmd): Use correct file descriptor in call to fdsock.
504 (cygwin_rexec): Ditto.
505
6fcd5661
CF
5062003-03-13 Christopher Faylor <cgf@redhat.com>
507
508 * fhandler_tty.cc (fhandler_tty_slave::close): Fix typo in debug
509 output.
510
511 * syscalls.cc (rename): Assume that DELETE_ON_CLOSE works on Win9x.
512
aa39b7f7
CV
5132003-03-11 Corinna Vinschen <corinna@vinschen.de>
514
515 * fhandler_socket.cc (fhandler_socket::dup): Don't call
516 fhandler_base::dup() but call DuplicateHandle directly instead to have
517 control over socket inheritence.
518
2afa7f58
CV
5192003-03-11 Corinna Vinschen <corinna@vinschen.de>
520
521 * fhandler_socket.cc (fhandler_socket::dup): On NT systems avoid
522 using WinSock2 socket duplication methods. Add comment.
523
5242003-03-11 Pierre Humblet <pierre.humblet@ieee.org>
525
526 * fhandler_socket.cc (fhandler_socket::fixup_after_fork):
527 Set io_handle to INVALID_SOCKET in case of failure.
528 (fhandler_socket::dup): Return 0 if the io_handle is valid.
529
556ceaeb
CV
5302003-03-10 Corinna Vinschen <corinna@vinschen.de>
531
532 * sec_acl.cc (setacl): Don't handle DELETE flag specially.
533 * security.cc (alloc_sd): Ditto.
534
a201401c
CV
5352003-03-09 Corinna Vinschen <corinna@vinschen.de>
536
6bbf711e 537 * winver.rc: Change Copyright hint to include 2003.
a201401c 538
b1aae492
CV
5392003-03-09 Corinna Vinschen <corinna@vinschen.de>
540
541 Switch to 32/64 datatypes:
542 * Makefile.in (OBSOLETE_FUNCTIONS): Add open acl aclcheck aclfrommode
543 aclfrompbits aclfromtext aclsort acltomode acltopbits acltotext chown
544 facl fchown fgetpos fopen freopen fseeko fsetpos fstat ftello
545 ftruncate getegid geteuid getgid getgrent getgrgid getgrnam getgroups
546 getpwuid getpwuid_r getuid initgroups lchown lseek lstat mknod mmap
547 seekdir setegid seteuid setgid setgroups setregid setreuid setuid stat
548 telldir truncate.
549 (NEW_FUNCTIONS): Add _open64 acl32 aclcheck32 aclfrommode32
550 aclfrompbits32 aclfromtext32 aclsort32 acltomode32 acltopbits32
551 acltotext32 chown32 facl32 fchown32 fgetpos64 fopen64 freopen64
552 fseeko64 fsetpos64 fstat64 ftello64 ftruncate64 getegid32 geteuid32
553 getgid32 getgrent32 getgrgid32 getgrnam32 getgroups32 getpwuid32
554 getpwuid_r32 getuid32 initgroups32 lchown32 lseek64 lstat64 mknod32
555 mmap64 seekdir64 setegid32 seteuid32 setgid32 setgroups32 setregid32
556 setreuid32 setuid32 stat64 telldir64 truncate64 to substitute the
557 above.
558 * cygserver_shm.h (class client_request_shm): Change uid_t and gid_t
559 members to __uid32_t and __gid32_t.
560 * cygwin.din: Add symbols acl32 aclcheck32 aclfrommode32
561 aclfrompbits32 aclfromtext32 aclsort32 acltomode32 acltopbits32
562 acltotext32 facl32 fgetpos64 fopen64 freopen64 fseeko64 fsetpos64
563 _fstat64 ftello64 _lseek64 mknod32 _open64.
564 * glob.c: Include perprocess.h.
565 (globtilde): Call getpwuid32 and getuid32 instead of getpwuid and
566 getuid.
567 (g_lstat): Check for applications API version to call the appropriate
568 typed gl_lstat function.
569 (g_stat): Ditto for gl_stat.
570 * shm.cc (client_request_shm::client_request_shm): Call geteuid32
571 and getegid32 instead of geteuid and getegid throughout.
572 * syscalls.cc (_open64): New alias for open.
573 (_lseek64): New alias for lseek64.
574 (_fstat64): New alias for fseek64.
575 (mknod32): New function.
576 (mknod): Calls mknod32 now.
577 * winsup.h: Make function declarations for getuid32, geteuid32,
578 and getpwuid32 accessible for plain C sources. Add declarations
579 for getegid32 and getpwnam.
580 * include/cygwin/version.h: Bum API minor number to 78.
581 * include/sys/cygwin.h: Guard C++ specific members of struct
582 per_process against inclusion in plain C sources.
583 * include/sys/mman.h (mman): Add guard to avoid type clash when
584 compiling Cygwin.
585
659fb3ff
CF
5862003-03-09 Christopher Faylor <cgf@redhat.com>
587
d580d86c 588 * include/cygwin/version.h: Bump DLL minor number to 22.
659fb3ff 589
c367dfd0
CF
5902003-03-09 Christopher Faylor <cgf@redhat.com>
591
592 Do some minor reformatting of 'extern "C"' use throughout.
593
5942003-03-06 Christopher January <chris@atomice.net>
595
596 * autoload.cc (GetSystemTimes): Define new autoload function.
597 * fhandler_proc.cc (proc_listing): Add cpuinfo and partitions entries.
598 (fhandler_proc::fill_filebuf): Add PROC_CPUINFO and PROC_PARTITIONS
599 cases.
600 (format_proc_uptime): Use GetSystemTimes if available.
601 (read_value): New macro.
602 (print): New macro.
603 (cpuid): New function.
604 (can_set_flag): New function.
605 (format_proc_cpuinfo): New function.
606 (format_proc_partitions): New function.
607
36c4a441
CF
6082003-03-09 Christopher Faylor <cgf@redhat.com>
609
610 * syscalls.cc (unlink): Attempt to be more clever about setting
611 attributes of file. Only open file in query mode to avoid having to
612 mess with security stuff for reading.
613
639ebe29
CV
6142003-03-09 Corinna Vinschen <corinna@vinschen.de>
615
616 * rmsym: Fix regular expression.
617
3a1d827f
CF
6182003-03-09 Christopher Faylor <cgf@redhat.com>
619
620 * Makefile.in: Change from using new-* to cygwin0 for temporary
621 targets.
622
ca0e9071
CV
6232003-03-09 Corinna Vinschen <corinna@vinschen.de>
624
625 * include/cygwin/socket.h: Set SOMAXCONN to Winsock2 value.
626
ed269cea
CF
6272003-03-08 Christopher Faylor <cgf@redhat.com>
628
629 * syscalls.cc (unlink): Always attempt to use FILE_FLAG_CLOSE_ON_DELETE
630 to delete files since this allows us to preserve the protection of hard
631 linked files.
632 (link): Generate full path for potentially recalculated .lnk target.
633
1114c3d0
CF
6342003-03-08 Christopher Faylor <cgf@redhat.com>
635
636 Revert below changes regarding _pinfo::cmdline.
637
d66ac2bc
CV
6382003-03-08 Corinna Vinschen <corinna@vinschen.de>
639
640 * external.cc (cygwin_internal): Change n to __off64_t to match change
641 of _pinfo::cmdline.
642 * fhandler.h (class fhandler_virtual): Change filesize member to
643 __off64_t.
644 * fhandler_proc.cc (format_proc_meminfo): Change to return __off64_t.
645 (format_proc_stat): Ditto.
646 (format_proc_uptime): Ditto.
647 * fhandler_process.cc (format_process_stat): Ditto.
648 (format_process_status): Ditto.
649 (format_process_statm): Ditto.
650 * pinfo.cc (_pinfo::cmdline): Expect __off64_t parameter.
651 * pinfo.h (class _pinfo): Change declaration of cmdline accordingly.
652
762520f3
CF
6532003-03-07 Christopher Faylor <cgf@redhat.com>
654
655 * path.h (PATH_LNK): New enum val.
656 (path_conv::is_lnk_symlink): New function. True if path represents
657 .lnk style symlink.
658 * path.cc (check_shortcut): Set PATH_LNK in pflags when appropriate.
659 (symlink_info::check): Ditto. Remove PATH_LNK from pflags initially.
660 * syscalls.cc (unlink): Always remove readonly attribute from a symlink
661 regardless of type.
662 (link): (from Corinna Vinschen) Allow links to symlinks. Reset
663 attributes on a symlink after successful link creation.
664 (chmod): Use is_lnk_symlink where appropriate.
665 (rename): Ditto.
666
6672003-03-07 Pierre Humblet <pierre.humblet@ieee.org>
668
669 * tty.cc (create_tty_master): Call GetComputerName instead of
670 cygwin_gethostname. Set ut_id.
671 * syscalls.cc (login): Call endutent.
672 (setutent): Do not seek after a fresh open.
673
6f8102cb
CV
6742003-03-07 Corinna Vinschen <corinna@vinschen.de>
675
676 * syscalls.cc (seteuid32): Fix formatting.
677
88243328
TP
6782003-03-04 Thomas Pfaff <tpfaff@gmx.net>
679
680 * thread.cc (MTinterface::fixup_after_fork): Initialize mainthread
681 prior to pthread objects.
762520f3 682
12390bc4
CV
6832003-03-04 Jason Tishler <jason@tishler.net>
684
685 * fhandler_socket.cc (fhandler_socket::dup): Initialize type.
686
c418817e
CF
6872003-03-03 Christopher Faylor <cgf@redhat.com>
688
689 * fhandler.h (fhandler_tty_slave::close): Declare new function.
690 (fhandler_tty_slave::dup): Declare new function.
691 (fhandler_tty_slave::fixup_after_function): Declare new function.
692 * fhandler_tty.cc (fhandler_tty_slave_open): Only increment
693 fhandler_console::open_fhs when associated with a pty.
694 (fhandler_tty_slave::close): Define new function. Decrement
695 fhandler_console::open_fhs when associated with a pty.
696 (fhandler_tty_slave::dup): Define new function. Increment
697 fhandler_console::open_fhs when associated with a pty.
698 (fhandler_tty_slave::fixup_after_fork): Define new function. Increment
699 fhandler_console::open_fhs when associated with a pty.
700
e11fe31b
CF
7012003-03-03 Christopher Faylor <cgf@redhat.com>
702
703 * fhandler_tty.cc (fhandler_pty_slave::open): Grudgingly increment
704 fhandler_console::open_fhs here.
705 (fhandler_pty_slave::close): Ditto for close.
706
cffdb4b1
CF
7072003-03-02 Christopher Faylor <cgf@redhat.com>
708
709 * lib/getopt.c: Refresh from NetBSD sources.
710
d5d2ffee
CF
7112003-03-02 Christopher Faylor <cgf@redhat.com>
712
713 * fhandler_console.cc (fhandler_console::close): Don't decrement
714 in use counter if in vfork fixup stage.
715
c2c6b170
CF
7162003-03-02 Christopher Faylor <cgf@redhat.com>
717
718 * lib/getopt.c: Nuke use of unneeded BSDisms.
719
8b19b43d
CF
7202003-03-02 Christopher Faylor <cgf@redhat.com>
721
722 * dll_init.cc (dll_list::load_after_fork): Don't revert to LoadLibrary
723 if LoadLibraryEx fails.
724 * dtable.cc (dtable::dec_console_fds): Eliminate.
725 (dtable::release): Don't treat console specially.
726 (dtable::build_fhandler): Ditto.
727 * dtable.h (console_fds): Eliminate.
728 (dtable::dec_console_fds): Eliminate.
729 (dtable::inc_console_fds): Eliminate.
730 * fhandler.h (fhandler_console::open_fhs): New static element.
731 * fhandler_console.cc (fhandler_console::open): Increment open_fs.
732 (fhandler_console::close): Call FreeConsole if no more open consoles
733 and ctty is not associated with the console.
734 * syscalls.cc (setsid): Simplify check for when to call FreeConsole.
735 (check_pty_fds): Eliminate definition.
736 * winsup.h (check_pty_fds): Eliminate declaration.
737
3efc65f7
CF
7382003-03-02 Christopher Faylor <cgf@redhat.com>
739
740 * dll_init.cc (dll_list::load_after_fork): Fix typo where result of
741 LoadLibrary was ignored.
742
5a082e9e
CV
7432003-03-01 Corinna Vinschen <corinna@vinschen.de>
744
745 * fhandler_socket.cc (fhandler_socket::bind): Open and write socket
746 file using Win32 calls.
747
9d913f07
CV
7482003-03-01 Corinna Vinschen <corinna@vinschen.de>
749
750 * fhandler_socket.cc (get_inet_addr): Open and read socket file using
751 Win32 calls.
752
005c3065
CF
7532003-02-28 Christopher Faylor <cgf@redhat.com>
754
755 * cygwin.din: Wrap atexit and exit with cygwin, thread-safe functions.
756 * dcrt0.cc (cygwin_atexit): New function.
757 (cygwin_exit): Ditto.
758
27b4082a
PH
7592003-02-28 Pierre Humblet <pierre.humblet@ieee.org>
760
761 * syscalls.cc (fstat64): Pass get_name () to pc.
005c3065 762 (access): Pass fn to stat_worker.
27b4082a
PH
763
7642003-03-27 Corinna Vinschen <corinna@vinschen.de>
5777b970
CV
765
766 * fhandler_socket.cc (class sock_event): New class managing Winsock
767 events for interruptible socket calls.
768 (fhandler_socket::connect): Move support for interruptible call to
769 class sock_event. Use class object instead.
770 (fhandler_socket::accept): Ditto. Remove useless casts.
771
005c3065 7722003-03-27 Thomas Pfaff <tpfaff@gmx.net>
5777b970
CV
773
774 * fhandler_socket.cc (fhandler_socket::connect): Add support for
775 an interruptable connect.
776
7b2ce663
CV
7772003-02-27 Pierre Humblet <pierre.humblet@ieee.org>
778
779 * uinfo.cc (internal_getlogin): Only update user.groups.pgsid
780 if the call to set the primary group succeeds.
781
0e7a60fe
CF
7822003-02-27 Christopher Faylor <cgf@redhat.com>
783
784 * cygthread::detach: Improve error message.
785
61a52599
CV
7862003-02-26 Pierre Humblet <pierre.humblet@ieee.org>
787
788 * sec_helper.cc (get_sids_info): debug_print owner_sid and group_sid.
789
6b9a9ce6
CV
7902003-02-25 Corinna Vinschen <corinna@vinschen.de>
791
792 * mmap.cc (mmap64): Fix returned address by taking the granularity
793 into account.
794
1ffc44aa
PH
7952003-02-23 Pierre Humblet <pierre.humblet@ieee.org>
796
797 * syslog.cc (syslog): Do not unlock the file before closing it
798 and remove debug_printf about stream errors.
799
a066f364
CF
8002003-02-22 Christopher Faylor <cgf@redhat.com>
801
802 * cygmalloc.h: Remove MORECORE_CANNOT_TRIM. It's not true.
803 # cygwin.din: Export mallinfo.
804 # malloc_wrapper.cc (mallinfo): New function.
805
878e60c5
CF
8062003-02-22 Pierre Humblet <pierre.humblet@ieee.org>
807
808 * syslog.cc (syslog): Do not print the Windows pid. Print the Cygwin
809 pid as an unsigned decimal. On Win95 print a timestamp and attempt to
810 lock the file up to four times in 3 ms.
811
b1d1e50d
CV
8122003-02-21 Corinna Vinschen <corinna@vinschen.de>
813
814 * fhandler_socket.cc (fhandler_socket::fhandler_socket): Fix compiler
815 warning.
816 (fhandler_socket::fstat): Simplify. Set st_uid/st_gid to effective
817 uid/gid of current process in case of open sockets.
818
cf762b08
CV
8192003-02-21 Corinna Vinschen <corinna@vinschen.de>
820
821 * dtable.cc (dtable::build_fhandler_from_name): Set some fhandler
822 data on sockets to evaluate AF_LOCAL sockets correctly.
823 (dtable::build_fhandler): Set unit number on sockets.
824 * fhandler.h (fhandler_socket): Add unit number.
825 (fhandler_socket::get_unit): New method.
826 * fhandler_socket.cc (fhandler_socket::fhandler_socket): Set unit
827 number.
828 (fhandler_socket::fstat): Reorganize to return more Linux-like
829 values.
830 * net.cc: include ctype.h.
831 (fdsock): Set unit number when building fhandler.
832 * path.cc (path_conv::check): Set device type to FH_SOCKET if file
833 is a AF_UNIX socket.
834 (get_devn): Evaluate unit for virtual socket devices.
835 (win32_device_name): Set windows path for sockets to unix_path with
836 just backslashes to keep the different names.
837 * syscalls.cc (fstat64): Don't override st_ino, st_dev and st_rdev
838 for sockets.
839 (stat_worker): Ditto.
840
8412003-02-21 Pierre Humblet <pierre.humblet@ieee.org>
842
843 * autoload.cc (AccessCheck): Add.
844 (DuplicateToken): Add.
845 * security.h (check_file_access): Declare.
846 * syscalls.cc (access): Convert path to Windows, check existence
847 and readonly attribute. Call check_file_access instead of acl_access.
848 * security.cc (check_file_access): Create.
849 * sec_acl (acl_access): Delete.
850
5cd82412
CF
8512003-02-19 Christopher Faylor <cgf@redhat.com>
852
853 * fhandler.cc (fhandler_base::open): Move some filesystem specific
854 stuff.
855 (fhandler_disk_file::open): Accept some filesystem specific stuff.
856 * sigproc.cc (wait_for_sigthread): Become slightly more thread safe.
857 (sig_send): Don't assume that signal thread is ready.
858
892d8962
CV
8592003-02-20 Corinna Vinschen <corinna@vinschen.de>
860
861 * wincap.h (wincap): Remove unnecessary definition of
862 supports_sparse_files.
863 * wincap.cc: Ditto.
864
518f5d49
CV
8652003-02-20 Corinna Vinschen <corinna@vinschen.de>
866
867 * fhandler_disk_file.cc (fhandler_disk_file::opendir): Check descriptor
868 created by cygheap_fdnew constructor.
869 * fhandler_virtual.cc (fhandler_virtual::opendir): Ditto.
870 * fhandler_socket.cc (fhandler_socket::accept): Ditto and move
871 creation of file descriptor behind blocking OS call.
872 * net.cc (cygwin_socket): Ditto.
873 (cygwin_rcmd): Ditto.
874 (cygwin_rresvport): Ditto.
875 (cygwin_rexec): Ditto.
876 (socketpair): Ditto.
877
3a88cf1b
CV
8782003-02-20 Corinna Vinschen <corinna@vinschen.de>
879
880 * autoload.cc (GetCompressedFileSize): Add.
881 * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Compute
882 st_blocks value from GetCompressedFileSize() if available.
883
79207923
CV
8842003-02-18 Vaclav Haisman <V.Haisman@sh.cvut.cz>
885
886 * wincap.h (wincaps::supports_sparse_files): New flag.
887 (wincapc::supports_sparse_files): New method.
888 * wincap.cc (wincap_unknown): Define value for the new flag.
889 (wincap_95): Ditto.
890 (wincap_95osr2): Ditto.
891 (wincap_98): Ditto.
892 (wincap_98se): Ditto.
893 (wincap_me): Ditto.
894 (wincap_nt3): Ditto.
895 (wincap_nt4): Ditto.
896 (wincap_nt4sp4): Ditto.
897 (wincap_2000): Ditto.
898 (wincap_xp): Ditto.
899 * path.h (path_conv::fs_flags): New method.
005c3065
CF
900 * fhandler_disk_file.cc: Include winioctl.h for DeviceIoControl.
901 (fhandler_disk_file::open): Set newly created and truncated files as
79207923
CV
902 sparse on platforms that support it.
903
afe13e84
CV
9042003-02-17 Pierre Humblet <pierre.humblet@ieee.org>
905
906 * grp.cc (internal_getgroups): Handle properly tokens with
907 no groups. Fix bug introduced on 2003-02-04.
908
8fc16812
CF
9092003-02-16 Christopher Faylor <cgf@redhat.com>
910
408e9b2f 911 * cygwin.din: Export all appropriate newlib libm functions. Sort.
8fc16812
CF
912 * include/cygwin/version.h: Bump API minor number.
913
f655eadf
CF
9142003-02-15 Christopher Faylor <cgf@redhat.com>
915
8fc16812 916 * cygwin.din: Export all appropriate newlib libc functions.
f655eadf
CF
917 * include/cygwin/version.h: Bump API minor number.
918
4d9ba012
CV
9192003-02-14 Jason Tishler <jason@tishler.net>
920
921 * mmap.cc (mprotect): Add missing break.
922
dff01e3a
CF
9232003-02-13 Christopher Faylor <cgf@redhat.com>
924
925 * exceptions.cc (try_to_debug): Don't reset priority when returning
926 from non-waitloop call.
d1d1797e
CF
927
9282003-02-13 Vaclav Haisman <V.Haisman@sh.cvut.cz>
005c3065 929 Christopher Faylor <cgf@redhat.com>
d1d1797e
CF
930
931 * fhandler_console.cc (fhandler_console::write_normal): Use MessageBeep
932 for bell sound.
933 * autoload.cc (MessageBeep): Add.
934
97c61aeb
CF
9352003-02-13 Christopher Faylor <cgf@redhat.com>
936
937 * include/cygwin/types.h: Use correct ifdef guard for u_ definitions.
938
a200c081
CF
9392003-02-13 Christopher Faylor <cgf@redhat.com>
940
941 * environ.cc (environ_init): Use strechr.
942
2858de3a
CF
9432003-02-13 Christopher Faylor <cgf@redhat.com>
944
945 * include/cygwin/in.h (sockaddr_in): Fix typo.
946
75c8a70c
CF
9472003-02-12 Christopher Faylor <cgf@redhat.com>
948
949 * path.h (path_conv): Reorganize slightly.
950
939d19b0
CF
9512003-02-12 Christopher Faylor <cgf@redhat.com>
952
953 * fhandler_tty.cc (process_input): Add sanity check to ensure that
954 console typeahead is cleared on signal.
955
7a44ba05
CF
9562003-02-12 Christopher Faylor <cgf@redhat.com>
957
958 * spawn.cc (linebuf::~linebuf): Resurrect commented out (for
959 debugging?) code.
960
407b8df6
CF
9612003-02-10 Ralf Habacker <ralf.habacker@freenet.de>
962
963 * include/cygwin/in.h (in_attr_t): Define new type.
964 * include/arpa/inet.h (inet_addr): Change return type to in_addr_t.
965 (inet_lnaof): Ditto.
966 (inet_netof): Ditto.
967 (inet_network): Ditto.
968
9692003-02-10 Christopher Faylor <cgf@redhat.com>
970
971 * include/cygwin/types.h: Move many *_t typedefs here. Protect them
972 with ifdefs.
973 * fhandler_disk_file.cc (fhandler_disk_file::fstat): Change ntsec_atts to mode_t.
974 * security.cc (get_attribute_from_acl): Accept mode_t attribute.
975 (get_nt_attribute): Ditto.
976 (get_file_attribute): Ditto.
977 (get_nt_object_attribute): Ditto.
978 (get_object_attribute): Ditto.
979 * security.h: Reflect above changes.
980 * syscalls.cc (chown_worker): Change attrib to mode_t.
981
ad80bc42
CF
9822003-02-08 Christopher Faylor <cgf@redhat.com>
983
67c64e3b 984 * include/cygwin/version.h: Bump DLL minor number to 21.
ad80bc42
CF
985
9862003-02-07 Christopher Faylor <cgf@redhat.com>
987
988 * malloc.cc (DEFAULT_MMAP_THRESHOLD): Bump down to 16MB thanks to below
989 changes.
990
4136fdb1
CV
9912003-02-07 Corinna Vinschen <corinna@vinschen.de>
992
993 * mmap.cc (mmap_record::alloc_map): De-inline. Add offset and length
994 parameter. Only protect pages actually unused currently. Do job
995 of map_map() when initializing a map.
996 (mmap_record::map_map): Reduce functionality for the reuse case
997 of private anonymous mapping.
998 (mmap_record::fixup_map): Format change.
999 (list::add_record): Add offset and length parameter to call
1000 mmap_record::alloc_map() correctly.
1001 (mmap64): Rename `l' variable to `map_list'. Accomodate above changes.
1002 (munmap): Rename `l' variable to `map_list'.
1003 (msync): Ditto.
1004 (fhandler_disk_file::mmap): Streamline code.
1005 (mprotect): Ditto.
1006 (fixup_mmaps_after_fork): Rename `l' variable to `map_list'.
1007
49b84ce4
CF
10082003-02-07 Vaclav Haisman <V.Haisman@sh.cvut.cz>
1009 Christopher Faylor <cgf@redhat.com>
1010
1011 * exceptions.cc (try_to_debug): Set priority of current thread rather
1012 than the main thread. Make busy waiting loop less busy. Restore
1013 priority when function returns.
1014
bc5b63ed
CF
10152003-02-07 Christopher Faylor <cgf@redhat.com>
1016
1017 * malloc.cc (DEFAULT_MMAP_THRESHOLD): Set high to avoid mmaps.
1018
10192003-02-07 Christopher Faylor <cgf@redhat.com>
1020
1021 * pipe.cc (fhandler_pipe::close): Avoid extraneous this->.
1022
1de8d164
CF
10232003-02-06 Christopher Faylor <cgf@redhat.com>
1024
1025 * heap.cc (heap_init): Remove debugging code.
1026
565e8015
CV
10272003-02-06 Pierre Humblet <pierre.humblet@ieee.org>
1028
1029 * security.h: Introduce names UNKNOWN_UID and UNKNOWN_GID and delete
1de8d164 1030 declaration of is_grp_member.
565e8015
CV
1031 * uinfo.cc (internal_getlogin): Use UNKNOWN_GID.
1032 * passwd.cc (pwdgrp::read_passwd): Use UNKNOWN_UID.
1033 * grp.cc (pwdgrp::read_group): Change group name to provide better
1034 feedback.
1035 (getgrgid): Use gid16togid32.
1036 * sec_helper.cc (is_grp_member): Delete.
1037
d238c1b4
CF
10382003-02-05 Christopher Faylor <cgf@redhat.com>
1039
1040 * path.cc: Change 'to_posix_p' to 'to_posix' throughout.
1041 (conv_path_list_buf_size): Accommodate relative paths.
1042
b7f52fe8
CF
10432003-02-05 Christopher Faylor <cgf@redhat.com>
1044
1045 * path.cc (etc::dir_changed): Fix debug printf.
1046
62cd433e
CV
10472003-02-05 Corinna Vinschen <corinna@vinschen.de>
1048
1049 * sec_acl.cc (setacl): Move all permission settings to beginning of
1050 loop. Set default rights to same values as in alloc_sd(). Set DELETE
1051 for owner and default owner only if S_IWOTH is given.
1052
10532003-02-05 Pierre Humblet <pierre.humblet@ieee.org>
1054
1055 * sec_acl.cc: Change all __aclent16_t to __aclent32_t except in
1056 wrapper function definitions. Replace call to the aclXYZ functions by
1057 calls aclXYZ32.
1058 (searchace): Change type of third argument to __uid32_t and use
1059 ILLEGAL_UID instead of -1;
1060 (setacl): Remove some initializations. Only give STANDARD_RIGHTS_WRITE
1061 for S_IWOTH. Replace -1 by ILLEGAL_UID.
1062 (getacl): Change type of owner_sid, group_sid and ace_sid to cygpsid.
1063 In last else clause, suppress second call to ace_sid.get_id and use
1064 TRUE in first call. Replace EqualSid by ==.
1065 (acl_access): Call internal_getgroups in USER and GROUP cases.
1066 (acecmp: Define static.
1067 (acl32): Create from 16 bit type.
1068 (facl32): Ditto.
1069 (lacl32): Ditto.
1070 (aclcheck32): Ditto.
1071 (aclsort32): Ditto.
1072 (acltomode32): Ditto.
1073 (aclfrommode32): Ditto.
1074 (acltopbits32): Ditto.
1075 (aclfrompbits32): Ditto.
1076 (acltotext32): Ditto.
1077 (aclfromtext32): Ditto, and use strechr.
1078 (acl16to32): Create.
1079 (acl): Make it a wrapper function.
1080 (facl): Ditto.
1081 (lacl): Ditto.
1082 (aclcheck): Ditto.
1083 (aclsort): Ditto.
1084 (acltomode): Ditto.
1085 (aclfrommode): Ditto.
1086 (acltopbits): Ditto.
1087 (aclfrompbits): Ditto.
1088 (acltotext): Ditto.
1089 (aclfromtext): Ditto.
1090 * security.cc (write_sd): Call set_process_privilege and check
1091 ownership.
1092 (alloc_sd): Remove call to set_process_privilege and the owner check.
1093
cadd065b
CF
10942003-02-05 Christopher Faylor <cgf@redhat.com>
1095
1096 * include/sys/cygwin.h: Use C-style comments.
1097
0c8455c3
CV
10982003-02-05 Pierre Humblet <pierre.humblet@ieee.org>
1099
1100 * sec_helper.cc (get_sids_info): New function.
1101 * security.cc (extract_nt_dom_user): Simplify with strechr.
1102 (get_user_groups): Initialize glen to MAX_SID_LEN.
1103 (get_user_local_groups): Ditto.
1104 (get_attribute_from_acl): Define ace_sid as cygpsid.
1105 (get_nt_attribute): Define owner_sid and group_sid as cygpsid.
1106 Call get_sids_info instead of cygsid.get_{u,g}id and is_grp_member.
1107 (get_nt_object_attribute): Ditto.
1108 (alloc_sd): Define ace_sid as cygpsid.
1109
5ae9331a
TP
11102003-02-04 Thomas Pfaff <tpfaff@gmx.net>
1111
1112 * syscalls.cc (struct system_cleanup_args): New struct.
1113 (system_cleanup): New function.
1114 (system): Use pthread_cleanup_push and _pop to save and restore
1115 signal handlers and sigprocmask.
1116
3dbafd87
CV
11172003-02-04 Corinna Vinschen <corinna@vinschen.de>
1118
1119 * path.cc (symlink): Create security attributes so that only the
1120 user can modify the symlink.
1121 * security.cc (set_security_attribute): Remove symlink special
1122 handling.
1123
0daf2561
CV
11242003-02-04 Pierre Humblet <pierre.humblet@ieee.org>
1125
1126 * grp.cc (internal_getgroups): Do not return without closing
1127 the process handle.
1128
4a21c2d5
CV
11292003-02-04 Pierre Humblet <pierre.humblet@ieee.org>
1130
1131 * security.h (class cygpsid): New class.
1132 (class cygsid): Use cygpsid as base. Remove members psid, get_id,
1133 get_uid, get_gid, string, debug_printf and the == and != operators.
1134 (cygsidlist::clear_supp): Only do work if setgroups has been called.
1135 * sec_helper.cc: Define sid_auth NO_COPY.
1136 (cygpsid::operator==): New operator.
1137 (cygpsid::get_id): New function.
1138 (cygpsid::string): New function.
1139 (cygsid::string): Delete.
1140 (cygsid::get_id): Delete.
1141 * pwdgrp.h: Change arguments of internal_getpwsid,
1142 internal_getgrsid and internal_getgroups to cygpsid.
1143 * passwd.cc (internal_getpwsid): Change argument from cygsid to cygpsid.
d238c1b4 1144 * grp.cc (internal_getgrsid): Ditto.
4a21c2d5
CV
1145 (internal_getgroups): Ditto.
1146
335556d5
CF
11472003-02-03 Christopher Faylor <cgf@redhat.com>
1148
1149 Eliminate most unneeded this-> pointers throughout.
1150
153e83c6
CV
11512003-02-03 Pierre Humblet <pierre.humblet@ieee.org>
1152
1153 * security.h: Add third argument to set_process_privilege.
1154 * autoload.cc: Add OpenThreadToken.
1155 * sec_helper.cc (set_process_privilege): Add and use use_thread
1156 argument.
1157 * security.cc (alloc_sd): Modify call to set_process_privilege.
1158 Remember the result in each process. If failed and file owner is not
1159 the user, fail.
1160
f0f3ea68
CV
11612003-02-03 Corinna Vinschen <corinna@vinschen.de>
1162
1163 * fhandler_socket.cc (fhandler_socket::recvfrom): Return buffer
1164 length and don't set errno in case of WSAEMSGSIZE error.
1165 (fhandler_socket::recvmsg): Ditto.
1166
6688a061
CF
11672003-02-01 Christopher Faylor <cgf@redhat.com>
1168
1169 * grp.cc (getgrent32): Only refresh group entries when at beginning.
1170 (internal_getgrsid): Only refresh if uninitialized.
1171 (internal_getgrent): Ditto.
1172 * passwd.cc (getpwent): Only refresh passwd entries when at beginning.
1173 (pwdgrp::read_passwd): linebuf *cannot* be NO_COPY.
1174 (internal_getpwsid): Only refresh if uninitialized.
1175 (getpass): No need to refresh passwd data here.
1176 * pwdgrp.h (refresh): Eliminate default.
1177
a5a93a62
CF
11782003-01-31 Christopher Faylor <cgf@redhat.com>
1179
1180 * dlfcn.cc (dlerror): Only report load errors once per error.
1181
b0a82a85
CF
11822003-01-31 Christopher Faylor <cgf@redhat.com>
1183
1184 * fhandler_serial.cc (fhandler_serial::open): Avoid extraneous setting
1185 of res.
1186
1187 * termios.cc (tcsetattr): Correctly record errno after tcsetattr call.
1188
11892003-01-31 Troy Curtiss <troyc@usa.net>
1190
1191 * fhandler_serial.cc (fhandler_serial::tcsetattr): Add error-checking
1192 so that if any Win32 SetComm*() calls fail, errno gets set to EINVAL
1193 and tcsetattr() returns -1. Catch invalid bitrates, mostly. If baud
1194 rate setting is B0, just drop DTR and leave Win32 DCB bitrate as-is
1195 since 0 is not a valid Win32 setting.
1196 (fhandler_serial::tcgetattr): If DTR is low, populate the bitrate as
1197 B0, otherwise get it from the DCB.
1198
949c3da1
CF
11992003-01-31 Christopher Faylor <cgf@redhat.com>
1200
1201 * passwd.cc (pwdgrp::read_passwd): linebuf *must* be static (from
1202 Pierre Humblet).
1203 * pwdgrp.h (pwdgrp::refresh): Avoid calling read function if we already
1204 have lock since that means we are in the process of reading the file.
1205
485d85bf
CF
12062003-01-31 Jason Tishler <jason@tishler.net>
1207
1208 * shared.cc (shared_info::heap_chunk_size): Use correct variable when
1209 reading HKLM.
1210
704ce461
CF
12112003-01-30 Christopher Faylor <cgf@redhat.com>
1212
1213 * fhandler_registry.cc (fhandler_registry::exists): Fix off-by-one
1214 error when inspecting path.
1215
ba6e1083
CF
12162003-01-29 Christopher Faylor <cgf@redhat.com>
1217
1218 * lib/getopt.c: Allow environment variable control of POSIXLY_INCORRECT
1219 behavior.
1220
12212003-01-28 Corinna Vinschen <corinna@vinschen.de>
01e3c897
CV
1222
1223 * fhandler_socket.cc (fhandler_socket::accept): On successful execution
1224 set connection state of returned socket to CONNECTED.
1225
dfb366da
CF
12262003-01-27 Christopher Faylor <cgf@redhat.com>
1227
1228 * passwd.cc (pwdgrp::parse_passwd): Be more unforgiving about
1229 non-numeric fields.
1230
03dba1de
CF
12312003-01-26 Christopher Faylor <cgf@redhat.com>
1232
1233 * uinfo.cc (pwdgrp::next_num): Remove check for NULL since it is no
1234 longer a valid return from next_str.
1235 (pwdgrp::add_line): Duh. Revert to use strchr.
1236
fea48988
CF
12372003-01-26 Christopher Faylor <cgf@redhat.com>
1238
ca6018a0 1239 * string.h (strechr): New function.
fea48988
CF
1240 * uinfo.cc (pwdgrp::next_str): Search only for input char in string.
1241 Return EOS on failure. Don't check for NULL since it shouldn't be
1242 possible.
1243 (pwdgrp::add_line): Revert to replacing '\n' in input line with '\0'.
1244 (pwdgrp::next_num): Pass explicit separator character to next_str.
1245 * grp.cc (pwdgrp::parse_group): Ditto.
1246 * passwd.cc (pwdgrp::parse_passwd): Ditto. Revamp test for garbage
1247 input.
1248 * pwdgrp.h (pwdgrp::next_str): Don't use default parameter.
1249
9a751621
CF
12502003-01-26 Christopher Faylor <cgf@redhat.com>
1251
1252 * uinfo.cc (pwdgrp::load): Regularize strace output. Add warning for
1253 CreateFile failure.
1254
c9133395
CF
12552003-01-26 Christopher Faylor <cgf@redhat.com>
1256
bdbd7fb6
CF
1257 * passwd.cc (pwdgrp::parse_passwd): Eliminate use of memset. The
1258 structure should always be completely filled out.
1259 * grp.cc (pwdgrp::parse_group): Ditto.
1260
12612003-01-26 Christopher Faylor <cgf@redhat.com>
1262
1263 * grp.cc (pwdgrp::parse_group): Fix off-by-one problem in allocating
c9133395 1264 gr_mem.
65037056
CF
1265
12662003-01-26 Christopher Faylor <cgf@redhat.com>
1267
1268 * include/sys/strace.h (paranoid_printf): Define as not being part of
1269 "all" output.
1270
12712003-01-25 Christopher Faylor <cgf@redhat.com>
1272
1273 * pwdgrp.h (pwdgrp::next_num): Rename from next_int. Returns
1274 true/false if parse operation succeeded.
1275 (pwdgrp::reparse): Remove.
1276 (pwdgrp::raw_ptr): New function. Returns pointer in line.
1277 (pwdgrp::next_num): New functions for parsing other than unsigned long.
1278 * grp.cc (pwdgrp::parse_group): Reinstate previous parsing behavior.
1279 Don't fill in fields with NULL and assign empty gr_mem to known pointer
1280 rather than doing a pointless calloc. Streamline gr_mem parsing.
1281 Don't increment curr_lines here.
1282 * passwd.cc (pwdgrp::parse_passwd): Use new behavior of next_num.
1283 Don't increment curr_lines here.
1284 * uinfo.cc (pwdgrp::next_str): Keep returning EOL if out of data.
1285 (pwdgrp::reparse): Remove.
1286 (pwdgrp::next_num): Rename from next_int. Return bool indicating
1287 success of parse, argument returns value parsed.
1288 (pwdgrp::add_line): Increment curr_lines here on successful parse.
1289 (pwdgrp::load): (from Pierre Humblet) Don't return status. Just report
1290 it here.
1291
a53ddfe6
CF
12922003-01-25 Christopher Faylor <cgf@redhat.com>
1293
1294 * pwdgrp.cc (pwdgrp::reparse): Declare.
1295 * uinfo.cc (pwdgrp::reparse): Define.
c9b99d0d 1296 * grp.cc (pwdgrp::parse_group): Use reparse.
a53ddfe6 1297
4f7e12dd
CV
12982003-01-25 Pierre Humblet <pierre.humblet@ieee.org>
1299
1300 * syscalls.cc (seteuid32): On Win95 get the pw entry. If it exists
1301 update the euid and call cygheap->user.set_name. Remove special
1302 handling of ILLEGAL_UID.
ba6e1083 1303 (setgid32): Add a debug_printf. On Win95, always set the egid.
4f7e12dd
CV
1304 Remove special handling of ILLEGAL_GID. Do not compare gid and gr_gid.
1305 * child_info.h (class cygheap_exec_info): Remove uid.
1306 * spawn.cc (spawn_guts): Do not set ciresrv.moreinfo->uid.
1307 * dcrto.cc (dll_crt0_1): Always call uinfo_init.
1308 * uinfo.cc (uinfo_init): Reorganize and close handle if needed.
1309 (cygheap_user::ontherange): Do not call internal_getpwnam if pw is NULL.
1310
45dbfc26
CF
13112003-01-24 Christopher Faylor <cgf@redhat.com>
1312
1313 * fhandler_console.cc (fhandler_console::send_winch_maybe): Reset
1314 scroll region if size changes.
1315
7d33eefa
CV
13162003-01-24 Pierre Humblet <pierre.humblet@ieee.org>
1317 Jason Tishler <jason@tishler.net>
1318
1319 * cygwin.din: Export setreuid32, setreuid, setregid32, setregid.
1320 * syscalls.cc (setreuid32): New function.
1321 (setreuid): Ditto.
1322 (setregid32): Ditto.
1323 (setregid): Ditto.
1324 * include/cygwin/version.h: Bump API minor number.
1325
ac413374 13262003-01-23 Christopher Faylor <cgf@redhat.com>
69fae986 1327
ac413374 1328 * pwdrp.h (pwdgrp::refresh): Lock entire test prior to reading.
2037688a 1329
ac413374 13302003-01-23 Christopher Faylor <cgf@redhat.com>
09a88426
CF
1331
1332 * grp.cc (pwdgrp::parse_group): Eliminate arg and use class member
1333 instead. Use next_str and next_int to parse arguments.
1334 * passwd.cc (pwdgrp::parse_passwd): Ditto.
1335 (grab_string): Eliminate.
1336 (grab_int): Ditto.
1337 * pwdgrp.h (pwdgrp::parse): Eliminate input arg.
1338 (pwdgrp::parse_passwd): Reflect above change.
1339 (pwdgrp::parse_group): Reflect above change.
1340 (pwdgrp::next_str): New function.
1341 (pwdgrp::next_int): Ditto.
1342 (pwdgrp::gets): Eliminate.
1343 * uinfo.cc (pwdgrp::next_str): New function.
1344 (pwdgrp::next_int): Ditto.
1345 (pwdgrp::add_line): Subsume gets.
1346 (pwdgrp::gets): Eliminate.
1347 (pwdgrp::load): Just call add_line to parse input buffer.
1348
ac413374
CF
13492003-01-22 Thomas Pfaff <tpfaff@gmx.net>
1350
1351 * include/pthread.h (PTHREAD_MUTEX_RECURSIVE): Revert changes from
1352 2003-01-09 mutex patch.
1353 (PTHREAD_MUTEX_ERRORCHECK): Ditto.
1354
13552003-01-22 Corinna Vinschen <corinna@vinschen.de>
1356
1357 * cygrun.c: Move from here to ../testsuite.
1358 * Makefile.in: Remove cygrun.exe dependencies.
1359
13602003-01-21 Jason Tishler <jason@tishler.net>
1361
1362 * cygwin.din: Export nanosleep().
1363 * signal.cc (nanosleep): New function.
1364 (sleep): Move old functionality to nanosleep(). Call nanosleep().
1365 (usleep): Remove old functionality. Call nanosleep().
1366 * include/cygwin/version.h: Bump API minor number.
1367
57394495
CF
13682003-01-21 Christopher Faylor <cgf@redhat.com>
1369
1370 * grp.cc: Call gr.refresh() rather than doing isunitialized tests
1371 throughout.
1372 (gr): Use constructor (sigh).
1373 (pwdgrp::parse_group): Rename from parse_grp.
1374 (pwdgrp::read_group): Rename from read_etc_group. Just call gr.load
1375 with a single argument.
1376 * passwd.cc: Call pr.refresh() rather than doing isunitialized tests
1377 throughout.
1378 (pr): Use constructor (sigh).
1379 (pwdgrp::parse_passwd): Rename from "parse_pwd".
1380 (pwdgrp::read_passwd): Rename from read_etc_passwd. Just call pr.load
1381 with a single argument.
1382 * pwdgrp.h (pwdgrp_state): Eliminate.
1383 (pwdgrp): Reflect above renamings.
1384 (pwdgrp::etc_ix): Rename from pwd_ix.
1385 (pwdgrp::read): New element.
1386 (pwdgrp::lock): New element.
1387 (pwdgrp::refresh): New function.
1388 (pwdgrp::load): Eliminate variations which take buffer arguments.
1389 (pwdgrp::pwdgrp): New constructors. Initialize mutex here.
1390 * uinfo.cc (pwdgrp::load): Accommodate pwd_ix -> etc_ix renaming.
1391 (pwdgrp::load): Set initialized state to true rather than setting state
1392 to loaded.
1393
984864e9
CF
13942003-01-21 Christopher Faylor <cgf@redhat.com>
1395
89f7e8d1 1396 * include/cygwin/version.h: Bump DLL minor number.
984864e9 1397
d8cde3a3
CF
13982003-01-21 Pierre Humblet <pierre.humblet@ieee.org>
1399
1400 * path.h (etc::change_possible): Revert the type to bool.
1401 (etc::set_last_modified): Remove obsolete function.
1402 * path.cc (etc::change_possible): Revert type to bool.
1403 (etc::test_file_change): Do not test for negative values of
1404 change_possible and do not set it to -res.
1405 (etc::dir_changed): When the handle is NULL, call memset instead of
09a88426
CF
1406 test_file_changed. When the handle is invalid, return true. Detect
1407 filename change in /etc.
d8cde3a3 1408 (etc::file_changed): Remove unneeded check for !fn[n].
33de631b 1409 * uinfo.cc (pwdgrp::load): Eliminate spurious setting of fh to NULL.
b99b804b 1410 * pwdgrp.h (pwdgrp::operator =): Eliminate.
d8cde3a3 1411
7905c4f1
CF
14122003-01-19 Christopher Faylor <cgf@redhat.com>
1413
1414 * pwdgrp.h (etc): Move to path.h.
1415 (pwdgrp::max_lines): New field.
1416 (pwdgrp::curr_lines): New field.
1417 (pwdgrp::pwdgrp_buf): Ditto.
1418 (pwdgrp_buf_elem_size): Ditto.
1419 (pwdgrp_parse): Ditto.
1420 (pwdgrp::gets): Just declare here.
1421 (pwdgrp::load): Ditto. Just take one argument.
1422 (pwdgrp::load): Define overloaded function accepting passwd buf.
1423 (pwdgrp::load): Define overloaded function accepting group buf.
1424 * grp.cc: Use pwdgrp elements rather than standalone static variables
1425 throughout.
1426 (curr_lines): Eliminate.
1427 (max_lines): Ditto.
1428 (add_grp_line): Ditto.
1429 (parse_grp): Define as returning boolean. Accept void * arg and line
1430 count. Coerce first argument into __group32 buf reference. Increment
1431 curr_line as appropriate.
1432 (read_etc_group): Pass pwdgrp buffer to gr.load.
1433 * passwd.cc: Use pwdgrp elements rather than standalone static variables
1434 throughout.
1435 (curr_lines): Eliminate.
1436 (max_lines): Ditto.
1437 (add_grp_line): Ditto.
1438 (parse_passwd): Define as returning boolean. Accept void * arg and line
1439 count. Coerce first argument into passwd buf reference. Increment
1440 curr_line as appropriate.
1441 (read_etc_group): Pass pwdgrp buffer to pr.load.
1442 * path.cc (etc::fn): Extend buffer size to allow index by 1 rather than
1443 zero.
1444 (etc::last_modified): Ditto.
1445 (etc::change_possible): Ditto. Renamed from sawchange. Change to
1446 signed char since elements are now tri-state.
1447 (etc::init): Assume "handle" is 1 based rather than 0.
1448 (etc::test_file_change): New function. Sets change_possible based on
1449 file date comparison.
1450 (etc::dir_changed): Check file states immediately after changed_h is
1451 initialized to avoid a race.
1452 (etc::file_changed): Use test_file_change to detect if file needs to be
1453 updated.
1454 * path.h (etc): Move class here from pwdgrp.h.
7905c4f1
CF
1455 * uinfo.cc: Move etc:: functions to path.cc. Move pwdgrp functions
1456 here.
1457 (pwdgrp::gets): Eliminate buf checks. Just check eptr and set lptr.
1458 (pwdgrp::add_line): New function.
1459 (pwdgrp::load): Call generic add_line function which will call correct
1460 parser.
1461
4c6a3e50
CF
14622003-01-17 Christopher Faylor <cgf@redhat.com>
1463
1464 * cygheap.cc: Change most 'int's to 'unsigned's.
1465 (_cmalloc): Only check for size of malloced region when calculating
97d2bc79 1466 bucket. Add overhead when performing the sbrk. Previous change broke
4c6a3e50
CF
1467 _crealloc.
1468
e9152439
CF
14692003-01-17 Christopher Faylor <cgf@redhat.com>
1470
1471 * dcrt0.cc (initialize_env): Use colon for CYGWIN_DEBUG separator.
1472 * grp.cc: Change most statics to NO_COPY throughout.
1473 * passwd.cc: Ditto.
1474
14752003-01-17 Christopher Faylor <cgf@redhat.com>
1476
1477 * pwdgrp.h: Change some BOOLs to bools.
1478 (pwdgrp::pwdgrp): Remove unneeded constructor.
1479 * passwd.cc: Change BOOL to bool throughout.
1480
afa378e7
CV
14812003-01-17 Corinna Vinschen <corinna@vinschen.de>
1482
1483 * cygwin.din: Add strerror_r.
1484 * include/cygwin/version.h: Bump API minor number.
1485
1de6f431
CF
14862003-01-17 Christopher Faylor <cgf@redhat.com>
1487
1488 * uinfo.cc (etc::dir_changed): Don't print a warning if can't open
1489 /etc, unless debugging.
1490
d8cde3a3 14912003-01-17 Pierre Humblet <pierre.humblet@ieee.org>
14ea5029
CF
1492
1493 * grp.cc (read_etc_group): On NT, add a line for gid = -1. Change name
1494 "unknown" to "mkgroup".
1495 (internal_getgrgid): Do not return default in nontsec case.
1496 (internal_getgroups): Add argument srchsid and look for it in groups if
1497 not NULL.
1498 * passwd.cc (read_etc_passwd): On NT, add a line for uid = -1. Use
1499 same default uid for Win95 and NT. Call cygheap_user::ontherange to
1500 initialize HOME.
1501
14ea5029
CF
15022003-01-16 Christopher Faylor <cgf@redhat.com>
1503
1504 * cygheap.cc (init_cygheap::etc_changed): Move to uinfo.cc.
1505 * cygheap.h (init_cygheap::etc_changed_h): Remove.
1506 (init_cygheap::etc_changed): Ditto.
1507 * grp.cc (group_state): Remove. Use gr instead throughout.
1508 (gr): Define as class pwdgrp.
1509 (read_etc_group): Remove gr definition. Remove calls to
1510 set_last_modified and close. Pass add_grp to gr.load to load file.
1511 * passwd.cc (passwd_state): Remove. Use pr instead, throughout.
1512 (pr): Define as class pwdgrp.
1513 (read_etc_passwd): Remove pr definition. Remove calls to
1514 set_last_modified and close. Pass add_pwd_line to pr.load to load
1515 file.
1516 * pwdgrp.h (etc): New helper class for pwdgrp.
1517 (pwdgrp): Combine pwdgrp_check and pwdgrp_read into one class. Remove
1518 file_w32 and last_modified fields.
1519 (pwdgrp::set_last_modified): Remove.
1520 (pwdgrp::isinitializing): Remove FindFirstFile stuff. Move to
1521 etc::file_changed.
1522 (pwdgrp::load): Rename from 'open'. Call etc::init to initialize etc
1523 scanning. Close file handle after reading buffer into memory. Parse
1524 buffer by calling second argument.
1525 (pwdgrp::gets): Reorganize slightly to rely on eptr starting at
5304bcdf 1526 beginning of buffer.
14ea5029
CF
1527 (pwdgrp::close): Remove.
1528 * uinfo.cc (etc::dir_changed): New function.
1529 (etc::init): Ditto.
1530 (etc::file_changed): Ditto.
1531 (etc::set_last_modified): Ditto.
1532
41429bc9
CV
15332003-01-16 Jason Tishler <jason@tishler.net>
1534
1535 * mmap.cc (fixup_mmaps_after_fork): Add ERROR_NOACCESS to the list of
1536 ReadProcessMemory() error codes that trigger a retry with temporary
1537 PAGE_READONLY access. Note that this can occur on NT 4.0.
1538
18813254
CF
15392003-01-15 Christopher Faylor <cgf@redhat.com>
1540
1541 * path.cc (normalize_posix_path): Convert win32 path separators to
1542 slashes when full path is specified.
1543
77cb0c56
CF
15442003-01-15 Pierre Humblet <pierre.humblet@ieee.org>
1545
1546 * cmalloc.cc (_cmalloc): Fix memory leak.
1547
ce542f78
CV
15482003-01-15 Corinna Vinschen <corinna@vinschen.de>
1549
1550 * autoload.cc: Fix copyright date.
1551 * fhandler_dsp.cc: Ditto.
1552 * mmap.cc: Ditto.
1553 * net.cc: Ditto.
1554 * ntdll.h: Ditto.
1555 * signal.cc: Ditto.
1556 * syscalls.cc: Ditto.
1557 * uname.cc: Ditto.
1558 * wait.cc: Ditto.
1559
15996b6f
CV
15602003-01-14 Corinna Vinschen <corinna@vinschen.de>
1561
1562 * mmap.cc (fixup_mmaps_after_fork): Copy protection to child process.
1563 Change ambiguous debug output.
1564
857b65dd
CV
15652003-01-14 Corinna Vinschen <corinna@vinschen.de>
1566
1567 * mmap.cc (mmap_record::access): Change argument type to caddr_t
1568 for strictness.
1569 (mprotect): Protect against calling VirtualProtect() for shared
1570 pages on 9x/Me.
1571 (fixup_mmaps_after_fork): If ReadProcessMemory() fails, try to
1572 change protection of parent page to PAGE_READONLY, then try again.
1573 Revert protection afterwards.
1574
e14328f4
TP
15752003-01-14 Thomas Pfaff <tpfaff@gmx.net>
1576
1577 * syscalls.cc (system): Add pthread_testcancel call.
1578 * thread.cc: Update list of cancellation points.
1579
4a3584c8
TP
15802003-01-14 Thomas Pfaff <tpfaff@gmx.net>
1581
1582 * wait.cc: Include thread.h
1583 (wait4): Add pthread_testcancel call.
1584 Wait for child process and cancellation event.
1585 * thread.cc: Update list of cancellation points.
1586
7ec66a2c
TP
15872003-01-14 Thomas Pfaff <tpfaff@gmx.net>
1588
1589 * signal.cc (sleep): Add pthread_testcancel call.
1590 Wait for signal and cancellation event.
1591 (usleep): Ditto.
1592
15932003-01-14 Thomas Pfaff <tpfaff@gmx.net>
3457ce4d
TP
1594
1595 * exceptions.cc (handle_sigsuspend): Add pthread_testcancel call.
1596 Wait for signal and cancellation event.
1597 * thread.cc: Update list of cancellation points.
1598
2673d5f2
CF
15992003-01-14 David Huang <davehzhr@hotmail.com>
1600
1601 * fhandler_dsp.cc (fhandler_dsp::ioctl): Add limited support for
1602 SNDCTL_DSP_GETFMTS.
1603
9f0d3f37
CF
16042003-01-12 Christopher Faylor <cgf@redhat.com>
1605
1606 * ntdll.h: Fix typo.
1607
7f129d87
CV
16082003-01-12 Corinna Vinschen <corinna@vinschen.de>
1609
1610 * uname.cc (uname): Use cygwin_gethostname() to retrieve hostname.
1611
ab2dbccc
CV
16122003-01-12 Pierre Humblet <pierre.humblet@ieee.org>
1613
1614 * sec_acl.cc (search_ace): Use id == -1, instead of < 0, as wildcard.
1615 (setacl): Start the search for a matching default at the next entry.
1616 Invalidate the type of merged entries instead of clearing it.
1617 Use well_known_creator for default owner and owning group and do
1618 not try to merge non-default and default entries in these cases.
1619 (getacl): Recognize well_known_creator for default owner and group.
1620 (acl_worker): Improve errno settings and streamline the nontsec case.
1621 * security.cc (write_sd): Remove the call to set_process_privilege.
1622 (alloc_sd): If the owner changes, call set_process_privilege and return
1623 immediately on failure. Change inheritance rules: on new directories add
1624 inherit only allow ACEs for creator_owner, creator_group and everyone.
1625 Preserve all inheritances through chmod and chown calls. Introduce
1626 isownergroup to implement the uid == gid case, to keep the inheritance
1627 code simple. Do not initialize owner_sid and group_sid and stop using
1628 the variable psd.
1629
68115c74
CF
16302003-01-10 Christopher Faylor <cgf@redhat.com>
1631
1632 * net.cc: Use gethostname define from winsock2.h.
1633
e3abf986
CF
16342003-01-10 Christopher Faylor <cgf@redhat.com>
1635
1636 * path.cc: Unrevert below reversion except for
1637 mount_info::conv_to_posix_path part.
1638
df2caa88
CV
16392003-01-10 Corinna Vinschen <corinna@vinschen.de>
1640
1641 * path.cc: Revert patch from 2003-01-09 to normalize a windows path
1642 rather than converting to posix.
1643
dc8d11f5
CV
16442003-01-10 Corinna Vinschen <corinna@vinschen.de>
1645
1646 * autoload.cc (gethostname): Make call optional, return 1 if function
1647 can't get loaded.
1648 * net.cc (cygwin_gethostname): Call GetComputerName if return value
1649 of gethostname is non-zero.
1650
70d61f30
CV
16512003-01-10 Charles Wilson <cwilson@ece.gatech.edu>
1652
8735f49f 1653 * cygwin.din: Add asprintf and vasprintf, as well as the reentrant
70d61f30 1654 versions and underscore variants.
8735f49f 1655 * include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR.
70d61f30 1656
a7711767
CV
16572003-01-10 Corinna Vinschen <corinna@vinschen.de>
1658
1659 * net.cc (cygwin_gethostname): Fix call to wsock function gethostname.
1660
d5223b2b
CF
16612003-01-09 Christopher Faylor <cgf@redhat.com>
1662
1663 * cygthread.cc (cygthread::cygthread): Be more noisy about odd
1664 condition.
1665 * miscfuncs.cc (low_priority_sleep): Sleep in regular priority if
1666 that's what we're currently running at.
1667
65f207e8
TP
16682003-01-09 Thomas Pfaff <tpfaff@gmx.net>
1669
1670 * include/semaphore.h: Modify typedef for sem_t.
1671 * include/cygwin/types.h: Modify typedefs for pthread_t,
1672 pthread_mutex_t, pthread_key_t, pthread_attr_t,
1673 pthread_mutexattr_t, pthread_condattr_t, pthread_cond_t,
1674 pthread_rwlock_t and pthread_rwlockattr_t.
1675
09cbb9d6
TP
16762003-01-09 Thomas Pfaff <tpfaff@gmx.net>
1677
1678 * thread.h (WAIT_CANCELED): New define.
1679 (pthread::cancelable_wait): New static method.
1680 * thread.cc (pthread::cancelable_wait): Implement.
1681 (semaphore::Wait): Wait on semaphore and thread cancellation.
1682 (pthread::join): Wait on joined thread and thread cancellation.
1683 (semaphore::wait): Add testcancel to check for thread
1684 cancellation even if the semaphore is available.
1685
5d68d1de
TP
16862003-01-09 Thomas Pfaff <tpfaff@gmx.net>
1687
1688 * include/pthread.h: Add define for errorchecking mutexes.
1689 Change default mutex type.
1690 * thread.cc (pthread_cond::TimedWait): Update mutex unlock
1691 calls.
1692 (pthread_mutex::pthread_mutex): New implement.
1693 (pthread_mutex::~pthread_mutex): Ditto.
1694 (pthread_mutex::Lock): Ditto.
1695 (pthread_mutex::TryLock): Ditto.
1696 (pthread_mutex::UnLock): Ditto.
1697 (pthread_mutex::Destroy): Implement new method.
1698 (pthread_mutex::SetOwner): Ditto.
1699 (pthread_mutex::LockRecursive): Ditto.
1700 (pthread_mutex::fixup_after_fork): Restore locking state after
1701 fork.
1702 (__pthread_mutex_lock): Return pthread_mutex::Lock errorcode.
1703 (__pthread_mutex_trylock): Return pthread_mutex::TryLock
1704 errorcode.
1705 (__pthread_mutex_unlock): Return pthread_mutex::UnLock
1706 errorcode.
1707 (__pthread_mutex_destroy): Call pthread_mutex::Destroy to
3457ce4d 1708 destroy mutex.
5d68d1de
TP
1709 (__pthread_mutexattr_settype): Allow errorchecking and recursive
1710 types.
1711 * thread.h (MUTEX_LOCK_COUNTER_INITIAL): New define.
1712 (pthread_mutex::criticalsection): Remove.
1713 (pthread_mutex::lock_counter): New member.
1714 (pthread_mutex::recursion_counter): Ditto.
1715 (pthread_mutex::owner): Ditto.
1716 (pthread_mutex::type): Ditto.
1717 (pthread_mutex::Destroy): New method.
1718 (pthread_mutex::SetOwner): Ditto.
1719 (pthread_mutex::LockRecursive): Ditto.
1720
ed9fe455
TP
17212003-01-09 Thomas Pfaff <tpfaff@gmx.net>
1722
1723 * pthread.cc (pthread_cond_init): Use new pthread_cond::init.
1724 * thread.cc: Some white spaces cleanups.
1725 Change __pthread_cond_init to pthread_cond::init throughout.
1726 (nativeMutex): Move class methods outside pthread_mutex.
1727 (MTinterface::Init): Initialize pthread_cond init lock.
1728 (pthread_cond::condInitializationLock): Instantiate.
1729 (pthread_cond::initMutex): New Method.
1730 (pthread_cond::isGoodInitializerOrBadObject): Ditto.
1731 * thread.h: Some white spaces cleanups.
1732 (nativeMutex): Move class declaration outside pthread_mutex.
1733 (pthread_cond::condInitializationLock): New static member.
1734 (pthread_cond::initMutex): New Method.
1735 (pthread_cond::isGoodInitializerOrBadObject): Ditto.
1736 (__pthread_cond_init): Remove prototype.
1737
93353aee
CV
17382003-01-09 Corinna Vinschen <corinna@vinschen.de>
1739
1740 * fhandler_disk_file.cc (num_entries): Return 2 as link count if
1741 directory unreadable.
1742
3eb27a4e
CV
17432003-01-09 Corinna Vinschen <corinna@vinschen.de>
1744
1745 * security.cc (get_nt_attribute): Always return -1 when read_sd()
1746 fails.
1747 (get_file_attribute): Set permissions to 0 and owner/group to -1
1748 if security descriptor is unreadable.
1749
85ba109d
CF
17502003-01-09 Christopher Faylor <cgf@redhat.com>
1751
1752 Use isdirsep rather than SLASH_P throughout.
1753 * path.cc (iscygdrive): Disallow /cygdrive\x.
1754 (normalize_posix_path): "Normalize" a windows path, if detected, rather
1755 than converting to posix.
1756
17572003-01-06 Troy Curtiss <troyc@usa.net>
1758
1759 * fhandler_serial.cc (fhandler_serial::tcsetattr): Add support and
1760 capability checking for B230400 bitrate.
1761 (fhandler_serial::tcgetattr): Add support for B230400 bitrate.
1762 * include/sys/termios.h: Add B230400 definition for Posix support of
1763 230.4Kbps.
1764
cbdbe9d7
CF
17652003-01-05 Christopher Faylor <cgf@redhat.com>
1766
1767 * pinfo.cc (_pinfo::commune_send): Use myself->lock rather than just
1768 lock when leaving.
1769
f3afe99b
CF
17702003-01-03 Christopher Faylor <cgf@redhat.com>
1771
1772 * dtable.h (dtable::in_vfork_cleanup): New function. True if vfork
1773 cleanup needed.
1774 * dtable.cc (dtable::vfork_parent_restore): Remove assertion.
1775 * pipe.cc (fhandler_pipe::close): Don't close read_state during
1776 fork_fixup since it wasn't inherited.
1777
2665fb15
CF
17782003-01-01 Christopher Faylor <cgf@redhat.com>
1779
1780 * passwd.cc (getpwuid_r32): Revert previous change.
1781
8619b42b
CF
17822003-01-01 Christopher Faylor <cgf@redhat.com>
1783
1784 * sysconf.cc (sysconf): Return arbitrary values for
1785 _SC_GETGR_R_SIZE_MAX, _SC_LOGIN_NAME_MAX, _SC_GETPW_R_SIZE_MAX.
1786
1787 * passwd.cc (getpwuid_r32): Add uid/gid fields to size check
1788 calculation.
1789
This page took 0.220322 seconds and 5 git commands to generate.