]>
Commit | Line | Data |
---|---|---|
dd0208eb CV |
1 | 2002-06-21 Corinna Vinschen <corinna@vinschen.de> |
2 | ||
3 | * security.cc (alloc_sd): Remove unnecessary retrieval of owner name. | |
4 | Check uid for current user first and use SIDs from cygheap if so. | |
5 | Set errno to EINVAL if user SID isn't retrievable. Just print user SID | |
6 | as debug output. | |
7 | Don't bail out if group SID isn't retrievable. Change debug output | |
8 | appropriately. | |
9 | ||
d7c2bd8e CF |
10 | 2002-06-21 Christopher Faylor <cgf@redhat.com> |
11 | ||
12 | * errno.cc: Change text description for EBADF throughout. | |
13 | ||
7c02f861 CF |
14 | 2002-06-20 Pierre Humblet <pierre.humblet@ieee.org> |
15 | ||
16 | * uinfo.cc (cygheap_user::ontherange): Use env_name for NetUserGetInfo. | |
17 | (cygheap_user::env_logsrv): Verify env_domain is valid. | |
18 | * environ.cc: Include child_info.h and keep spenvs[] sorted. | |
19 | (environ_init): Check child_proc_info instead of myself->ppid_handle. | |
20 | ||
c25ebbaf CF |
21 | 2002-06-19 Christopher Faylor <cgf@redhat.com> |
22 | ||
23 | * fhandler.cc (fhandler_base::set_flags): Change priority of "linked | |
24 | in" default binmode setting so that it has priority over optional | |
25 | setting. | |
26 | ||
03a2ce9a CF |
27 | 2002-06-19 Christopher Faylor <cgf@redhat.com> |
28 | ||
d70b993f | 29 | Use hMainProc where appropriate, throughout. |
03a2ce9a CF |
30 | * environ.cc (spenv::retrieve): Add debugging statements. |
31 | ||
32 | * pinfo.cc (set_myself): Don't call strace.hello if already stracing. | |
33 | * strace.cc (strace): Move NO_COPY keyword so that it will actually | |
34 | take effect. | |
35 | ||
834224ab CV |
36 | 2002-06-19 Corinna Vinschen <corinna@vinschen.de> |
37 | ||
38 | * uinfo.cc (cygheap_user::ontherange): Call NetUserGetInfo() only with | |
39 | non-NULL logserver parameter. | |
40 | ||
e40670ee CF |
41 | 2002-06-16 Christopher Faylor <cgf@redhat.com> |
42 | ||
43 | * cygheap.h (cygheap_user::issetuid): New method. | |
44 | * dtable.cc (dtable::vfork_child_dup): Use new method to determine if | |
45 | we are in "setuid mode." | |
46 | * fork.cc (fork_parent): Ditto. | |
47 | * spawn.cc (spawn_guts): Ditto. | |
48 | * syscalls.cc (seteuid32): Ditto. | |
49 | (setegid32): Ditto. | |
50 | * environ.cc (spenv::retrieve): (Suggested by Pierre Humblet) Do | |
51 | potential recalculation of cygheap_user stuff when in setuid mode. | |
00a9e8a0 CF |
52 | Return special value when environment variable should be calculated but |
53 | not added. | |
e40670ee CF |
54 | (build_env): Don't add retrieved value to dstp if it is 'dont_add'. |
55 | ||
a05a9e01 CF |
56 | 2002-06-16 Christopher Faylor <cgf@redhat.com> |
57 | ||
58 | Changes suggested by Pierre Humblet. | |
59 | * environ.cc (NL): New macro. | |
60 | (conv_envvars): Use NL macro to fill in name and namelen. | |
61 | (spenv::namelen): New field. | |
62 | (spenvs): Use NL to fill in name and namelen. | |
63 | (spenv::retrieve): Eliminate length argument. Instead, use namelen | |
64 | throughout. | |
65 | (build_env): Don't calculate length of initial FOO= part of | |
66 | environment. Accommodate spenv::retrive argument change. | |
67 | ||
5f25e1d1 CF |
68 | 2002-06-16 Christopher Faylor <cgf@redhat.com> |
69 | ||
70 | * cygheap.h (cygheap_user::winname): New field. | |
71 | * cygheap.cc (cygheap_user::set_name): Clear winname when name changes. | |
72 | * uinfo.cc (cygheap_user::env_logsrv): Avoid calculating server when | |
73 | Windows user == SYSTEM. | |
74 | (cygheap_user::env_domain): Set winname here too. | |
75 | (cygheap_user::env_userprofile): Eliminate superfluous tests. | |
76 | (cygheap_user::env_name): Seed winname by calling env_domain(). | |
77 | ||
5c8bce24 CF |
78 | 2002-06-12 Pierre Humblet <pierre.humblet@ieee.org> |
79 | ||
80 | * spawn.cc (spawn_guts): Revert removal of ciresrv.moreinfo->uid = | |
81 | ILLEGAL_UID. | |
82 | ||
6ea3e429 CF |
83 | 2002-06-15 Christopher Faylor <cgf@redhat.com> |
84 | ||
85 | * child_info.h (child_proc_info): Declare as base class. | |
86 | (spawn_info): Declare as alias of child_proc_info to aid debugging. | |
87 | (fork_info): Ditto. | |
88 | * cygheap.cc (cygheap_fixup_in_child): Use child_proc_info global | |
89 | rather than parameter. | |
90 | * cygheap.h (cygheap_fixup_in_child): Reflect above change in | |
91 | declaration. | |
92 | * dcrt0.cc (_dll_crt0): Move 'si' definition here. Assign | |
93 | child_proc_info. | |
94 | (dll_crt0_1): Accommodate cygheap_fixup_in_child and *_info changes. | |
95 | * environ.cc (spenv::retrieve): Make regparm. | |
96 | * environ.h (environ_init): Ditto. | |
97 | (win_env::add_cache): Ditto. | |
98 | (build_env): Ditto. | |
99 | (getwinenv): Ditto. | |
100 | * fork.cc (sync_with_parent): Use fork_info global. | |
101 | (fork_child): Ditto. | |
102 | ||
cff111a6 CF |
103 | 2002-06-14 Christopher Faylor <cgf@redhat.com> |
104 | ||
105 | * uinfo.cc (cygheap_user::ontherange): Don't set HOMEDRIVE or HOMEPATH | |
106 | unless one or the other is specified. | |
107 | ||
6d171b44 CF |
108 | 2002-06-14 Christopher Faylor <cgf@redhat.com> |
109 | ||
110 | * cygheap.h (cygheap_user::userprofile_env_buf): New static member. | |
111 | * environ.cc (build_env): Add debugging statement. | |
112 | (spenvs): Switch functions for USERDOMAIN and USERNAME. | |
113 | * spawn.cc (spawn_guts): Move environment initialization prior to | |
114 | cygheap_setup_for_child or environment info will never be copied to | |
115 | child. | |
116 | ||
a77d35f7 CF |
117 | 2002-06-14 Christopher Faylor <cgf@redhat.com> |
118 | ||
119 | * cygheap.h (cygheap_user): Add static members to hold home{drive,path} | |
120 | info. | |
121 | * uinfo.cc (cygheap_user::ontherange): Use static class members for | |
122 | local HOME* storage. | |
123 | ||
9a771b29 CF |
124 | 2002-06-14 Christopher Faylor <cgf@redhat.com> |
125 | ||
126 | * cygheap.cc (cygheap_user::set_logsrv): Remove. | |
127 | (cygheap_user::set_domain): Ditto. | |
128 | * cygheap.h (cygheap_user::set_logsrv): Remove declaration. | |
129 | (cygheap_user::set_domain): Ditto. | |
130 | (cygheap_user::env_domain): Declare new method. | |
131 | (cygheap_user::env_name): Ditto. | |
132 | * environ.cc (spenvs): Add two environment variables. | |
133 | * spawn.cc (spawn_guts): Call build_env after RevertToSelf. Always set | |
134 | ciresrv.mount_h. | |
135 | (cygheap_user::ontherange): Recalculate homedrive/homepath if they are | |
136 | empty. Use env_logsrv to get logon server. | |
137 | (cygheap_user::env_logsrv): Calculate server name here rather than | |
138 | relying on it having been previously calculated. | |
139 | (cygheap_user::env_domain): Ditto for domain name. | |
140 | (cygheap-user::env_name): New method. | |
141 | ||
142 | 2002-06-12 Pierre Humblet <pierre.humblet@ieee.org> | |
143 | ||
144 | * syscalls.cc (seteuid32): Do not get or set the environment. Do not | |
145 | call LookupAccountSid nor internal_getlogin. Set cygheap->user name | |
146 | and sid from the passwd entry. | |
147 | * uinfo.cc (uinfo_init): Only call internal_getlogin when starting from | |
148 | a non Cygwin process and use the values returned in user. | |
149 | (internal_getlogin): Simplify to case where starting from a non Cygwin | |
150 | process. Store return values in user and return void. Do not set the | |
151 | Windows default environment. | |
152 | * dcrt0.cc (dll_crt0_1): Call uinfo_init only when needed. Do not set | |
153 | myself->uid nor reset user.sid. | |
154 | * spawn.cc (spawn_guts): Get the sid from cygheap->user. Always | |
155 | RevertToSelf(). Don't set uid in impersonated case. | |
156 | * cygheap.cc (cygheap_user::set_sid): Do not set orig_sig. | |
157 | (cygheap_user::set_orig_sid): New. | |
158 | * cygheap.h: Declare cygheap_user::set_sid. | |
159 | * winsup.h: Add argument to uinfo_init(). | |
160 | ||
470e8c46 CV |
161 | 2002-06-14 Corinna Vinschen <corinna@vinschen.de> |
162 | ||
163 | * environ.cc (build_env): If realloc moves envblock, move s with it. | |
164 | ||
39be53dc CF |
165 | 2002-06-13 Nicholas S. Wourms <nwourms@netscape.net> |
166 | ||
167 | * winver.rc: Add more words to copyright. | |
168 | ||
0e6d80e4 CV |
169 | 2002-06-13 Corinna Vinschen <corinna@vinschen.de> |
170 | ||
171 | * cygheap.cc (cygheap_user::set_name): Revert previous change. | |
172 | * environ.cc (spenv::retrieve): Check return value of call to | |
173 | cygheap->user.*from_cygheap(). | |
174 | ||
5682a6dd CV |
175 | 2002-06-13 Corinna Vinschen <corinna@vinschen.de> |
176 | ||
177 | * cygheap.cc (cygheap_user::set_name): Remove setting homedrive and | |
178 | homepath to NULL. | |
179 | (cygheap_user::set_logsrv): Fix free'ing of plogsrv. | |
180 | * cygheap.h (cygheap_user::cygheap_user): Initialize homedrive and | |
181 | homepath to NULL. | |
182 | ||
5f74ae83 CF |
183 | 2002-06-13 Christopher Faylor <cgf@redhat.com> |
184 | ||
185 | * security.cc (get_logon_server): Use strcasematch rather than | |
186 | strcasecmp. | |
187 | ||
4863867a CF |
188 | 2002-06-12 Christopher Faylor <cgf@redhat.com> |
189 | ||
190 | * path.cc (chdir): Minor cleanup. | |
191 | ||
12a2ef44 CF |
192 | 2002-06-12 Christopher Faylor <cgf@redhat.com> |
193 | ||
194 | * environ.cc (build_env): Correctly fill out windows environment block | |
195 | with win32 paths rather than posix paths. | |
196 | ||
da086d02 CF |
197 | 2002-06-12 Christopher Faylor <cgf@redhat.com> |
198 | ||
199 | * cygheap.cc (cygheap_user::set_name): Set homedrive and homepath to | |
200 | NULL on user name change. | |
201 | (cygheap_user::set_logsrv): Allocate enough space for leading \\ so | |
202 | that we can put this in the environment, if needed. | |
203 | * cygheap.h (homebodies): New enum. | |
204 | (cygheap_user::homedrive): New field. | |
205 | (cygheap_user::homepath): Ditto. | |
206 | (cygheap_user::env_logsrv): New method. | |
207 | (cygheap_user::env_homepath): New method. | |
208 | (cygheap_user::env_homedrive): New method. | |
209 | (cygheap_user::env_userprofile): New method. | |
210 | (cygheap_user::ontherange): New method. | |
211 | * environ.cc (envsize): Eliminate debugging argument. | |
212 | (environ_init): Assume that envc counts number of elments not total | |
213 | size. | |
214 | (spenv): New class. | |
215 | (spenvs): New array, renamed from forced_winenv_vars, using spenv. | |
216 | (spenv::retrieve): New method. | |
217 | (build_env): Rename from 'winenv' -- one stop shopping for building new | |
218 | environment blocks for both windows and "unix". | |
219 | * environ.h (build_env: Declare. | |
220 | (winenv): Delete declaration. | |
221 | (envsize): Ditto. | |
222 | * spawn.cc (spawn_guts): Use build_env to build windows and cygwin | |
223 | environment blocks. | |
224 | * uinfo.cc (internal_getlogin): Eliminate environment manipulation. | |
225 | Default to info from GetUserName if it exists. Move HOMEPATH and | |
226 | HOMEDRIVE stuff elsewhere. Move HOME setting elsewhere. Only set HOME | |
227 | environment variable in processes that are not parented by a cygwin | |
228 | process. | |
229 | (cygheap_user::ontherange): Define new method. | |
230 | (cygheap_user::env_logsrv): Ditto. | |
231 | (cygheap_user::env_homepath): Ditto. | |
232 | (cygheap_user::env_homedrive): Ditto. | |
233 | (cygheap_user::env_userprofile): Ditto. | |
234 | ||
077d8b23 CF |
235 | 2002-06-11 Christopher Faylor <cgf@redhat.com> |
236 | ||
237 | * spawn.cc (spawn_guts): More hToken removal cleanup. | |
238 | ||
d5377829 CF |
239 | 2002-06-09 Pierre Humblet <pierre.humblet@ieee.org> |
240 | ||
241 | * spawn.cc (spawn_guts): Define sec_attribs and call sec_user_nih() | |
242 | only once. | |
243 | ||
380aaf2d CF |
244 | 2002-06-10 Christopher Faylor <cgf@redhat.com> |
245 | ||
246 | * Makefile.in: Ensure that -MD gets added to CFLAGS regardless of | |
247 | CFLAGS command-line setting. | |
248 | ||
249 | * cygwin.din: Export sexec* functions as function which returns ENOSYS | |
250 | (i.e., sexec* is deprecated). | |
251 | * dtable.cc (dtable::vfork_child_dup): Ensure that impersonation is | |
252 | restored even on failure. | |
253 | * exec.cc: Throughout, remove references to sexec* and _spawnve. | |
254 | * pinfo.h: Remove _spawnve declaration. | |
255 | * spawn.cc: Rename _spawnve to spawnve and use throughout. | |
256 | (spawn_guts): Eliminate hToken argument and processing of same. Just | |
257 | perform special actions if impersonating. | |
258 | (spawnve): Rename from _spawnve. | |
259 | ||
b01cbd5d CF |
260 | 2002-06-10 Christopher Faylor <cgf@redhat.com> |
261 | ||
262 | * include/sys/strace.h (strace): Avoid use of constructor. | |
263 | ||
fe4283af CF |
264 | 2002-06-10 Christopher Faylor <cgf@redhat.com> |
265 | ||
266 | * dcrt0.cc (dll_crt0_1): Initialize wincap and check for sanity before | |
267 | running global ctors. | |
268 | * wincap.h (wincap): Eliminate constructor. Default is to zero memory, | |
269 | anyway. | |
270 | * wincap.cc (wincap): Copy this on fork to avoid initialization in | |
271 | forked processes. | |
272 | ||
3d78e129 CV |
273 | 2002-06-10 Corinna Vinschen <corinna@vinschen.de> |
274 | ||
275 | * fhandler.h (fhandler_socket::fixup_after_fork): Revert patch from | |
276 | 2002-06-04. | |
277 | * fhandler_socket.cc (fhandler_socket::fixup_after_fork): Ditto. | |
278 | (fhandler_socket::dup): Ditto. | |
279 | * net.cc (fdsock): Make sockets explicitely noninheritable on NT. | |
280 | ||
c2102631 CF |
281 | 2002-06-09 Christopher Faylor <cgf@redhat.com> |
282 | ||
283 | * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Correctly | |
284 | set number of links for directory, if appropriate. | |
285 | ||
43c3c4e3 RC |
286 | 2002-06-10 Robert Collins <rbtcollins@hotmail.com> |
287 | ||
288 | * thread.cc: Variation of a patch from Thomas Pffaf. | |
d70b993f | 289 | (__pthread_detach): Cleanup thread object if the thread has terminated. |
43c3c4e3 RC |
290 | (__pthread_join): Change order of error checks, and lock against |
291 | join/detach/exit races. | |
292 | (__pthread_exit): Lock object against join/detach/exit races. | |
293 | (pthread::thread_init_wrapper): Ditto. | |
294 | (thread_init_wrapper): Rename to pthread::thread_init_wrapper. | |
295 | (pthread::create): Check that the mutex initialized correctly. | |
296 | (pthread::push_cleanup_handler): Lock against potential cancellation | |
297 | race. NB: this may not be required if pthread_cleanup_push is non- | |
298 | cancelable. | |
299 | * thread.h (pthread::mutex): New member. | |
300 | (thread_init_wrapper): Rename to pthread::thread_init_wrapper. | |
301 | (pthread::thread_init_wrapper_: New static member. | |
302 | ||
007276b3 RC |
303 | 2002-06-10 Robert Collins <rbtcollins@hotmail.com> |
304 | ||
305 | * cygwin.din: Add _pthread_cleanup_push and _pthread_cleanup_pop. | |
306 | * pthread.cc: Change __pthread_self to pthread::self() thruoghout. | |
307 | (_pthread_cleanup_push): New function. | |
308 | (_pthread_cleanup_pop): Ditto. | |
309 | * thread.cc: Thanks to Thomas Pfaff for the pthread cleanup_push,_pop | |
310 | patch, this work is derived from that. | |
311 | Change __pthread_self to pthread::self() thruoghout. | |
312 | (__pthread_self): Rename to pthread::self. | |
313 | (pthread::self): New method. | |
314 | (pthread::pthread): Initialize new member. | |
315 | (pthread::push_cleanup_handler): New method. | |
316 | (pthread::pop_cleanup_handler): New method. | |
317 | (pthread::pop_all_cleanup_handlers): New method. | |
318 | (__pthread_exit): Pop all cleanup handlers. | |
319 | * thread.h (pthread::push_cleanup_handler): Declare. | |
320 | (pthread::pop_cleanup_handler): Ditto. | |
321 | (pthread::pop_all_cleanup_handlers): Ditto. | |
322 | (pthread::self): New static method. | |
323 | (__pthread_exit): Give C++ linkage. | |
324 | (__pthread_join): Ditto. | |
325 | (__pthread_detach): Ditto. | |
326 | (__pthread_self): Remove. | |
327 | ||
328 | 2002-04-24 Thomas Pfaff <tpfaff@gmx.net> | |
329 | ||
c2102631 CF |
330 | * include/pthread.h (__pthread_cleanup_handler): New structure. |
331 | (pthread_cleanup_push): Rewritten. | |
007276b3 RC |
332 | (pthread_cleanup_pop): Ditto. |
333 | (_pthread_cleanup_push): New prototype. | |
c2102631 | 334 | (_pthread_cleanup_pop): Ditto. |
007276b3 RC |
335 | |
336 | 2002-04-24 Thomas Pfaff <tpfaff@gmx.net> | |
337 | ||
338 | * thread.cc (thread_init_wrapper): Check if thread is already joined. | |
339 | (__pthread_join): Set joiner first. | |
340 | (__pthread_detach): Ditto. | |
341 | ||
fec98ec9 RC |
342 | 2002-06-10 Robert Collins <rbtcollins@hotmail.com> |
343 | ||
344 | * cygserver_transport.cc (create_server_transport): Finish the split | |
345 | out of sockets code from transport_layer_base. Thanks to Nicholas | |
346 | Wourms and Conrad Scott for catching this. | |
347 | ||
7ac66bdd CF |
348 | 2002-06-08 Christopher Faylor <cgf@redhat.com> |
349 | ||
350 | * pinfo.cc (pinfo_dummy): Initialize to correct size. | |
351 | ||
a004a5b8 CF |
352 | 2002-06-08 Christopher Faylor <cgf@redhat.com> |
353 | ||
354 | * path.cc: Change MOUNT_AUTO to MOUNT_CYGDRIVE throughout. | |
355 | * shared_info.h (CURR_MOUNT_MAGIC): Update. | |
356 | ||
50484e8e CF |
357 | 2002-06-08 Christopher Faylor <cgf@redhat.com> |
358 | ||
359 | * external.cc (cygwin_internal): Make v1 mount table access invalid. | |
360 | * path.cc (mount_info::init): Remove had_to_create_mount_areas initialization. | |
361 | (mount_info::from_registry): Remove v1 table import. | |
362 | (mount_info::read_v1_mounts): Eliminate. | |
363 | (mount_info::import_v1_mounts): Ditto. | |
364 | * shared_info.h (mount_info): Ditto for both of above. | |
365 | * sys/mount.h (MOUNT_DEVFS): New enum. | |
366 | (MOUNT_PROC): Ditto. | |
367 | ||
2e2dcba3 CF |
368 | 2002-06-08 Christopher Faylor <cgf@redhat.com> |
369 | ||
370 | * include/wchar.h: Define __need_size_t. | |
371 | ||
9cde3cf3 CF |
372 | 2002-06-07 Christopher Faylor <cgf@redhat.com> |
373 | ||
374 | * fhandler_socket.cc (fhandler_socket::fstat): Don't assume that socket | |
375 | is unix-domain socket. | |
376 | ||
377 | 2002-06-07 Christopher Faylor <cgf@redhat.com> | |
378 | ||
379 | * times.cc (hires_ms::prime): Set init flag. | |
380 | ||
381 | 2002-06-07 Conrad Scott <conrad.scott@dsl.pipex.com> | |
382 | ||
383 | * times.cc (hires_ms::prime): Adjust epoch of initime_us from 1601 to | |
384 | 1970. | |
385 | ||
9d0efbb3 CF |
386 | 2002-06-06 Christopher Faylor <cgf@redhat.com> |
387 | ||
388 | * autoload.cc (timeGetDevCaps): Define new autoload function. | |
389 | (timeGetTime): Ditto. | |
390 | (timeBeginPeriod): Ditto. | |
391 | (timeEndPeriod): Ditto. | |
392 | * hires.h (hires_base): New class. Renamed from hires. | |
393 | (hires_us): New class. | |
394 | (hires_ms): New class. | |
395 | * strace.cc (strace::microseconds): Use hires_us class. | |
396 | * times.cc (gettimeofday): Use hires-ms class. | |
397 | (hires_us::prime): Renamed from hires::prime. | |
398 | (hires_us::usecs): Renamed from hires:usecs. | |
399 | (hires_ms::prime): New method. | |
400 | (hires_ms::usecs): New method. | |
401 | (hires_ms::~hires_ms): New destructor. | |
402 | ||
46b941fc CF |
403 | 2002-06-06 Christopher Faylor <cgf@redhat.com> |
404 | ||
405 | * autoload.cc (noload): Correctly save argument count register. | |
406 | ||
c4e6ff48 CV |
407 | 2002-06-05 Conrad Scott <conrad.scott@dsl.pipex.com> |
408 | ||
409 | * fhandler.cc (fhandler_base::fstat): Initialise tv_nsec member of | |
410 | st_atim, st_mtim, and st_ctim fields. | |
411 | * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Ditto. | |
412 | * fhandler_process.cc (fhandler_process::fstat): Ditto. | |
46b941fc CF |
413 | * glob.c (stat32_to_STAT): Copy across the whole st_atim, st_mtime, and |
414 | st_ctim fields. | |
c4e6ff48 CV |
415 | * syscalls.cc (stat64_to_stat32): Ditto. |
416 | * times.cc (to_timestruc_t): New function. | |
417 | (time_as_timestruc_t): New function. | |
418 | * winsup.h: Add to_timestruc_t and time_as_timestruc_t functions. | |
46b941fc CF |
419 | * include/cygwin/stat.h: Replace time_t with timestruc_t throughout for |
420 | all file times, removing the st_spare1, st_spare2, and st_spare3 fields | |
421 | in the process. Add macros to access tv_sec fields by old names. | |
422 | * include/cygwin/types.h: Typedef timespec_t and timestruc_t as struct | |
423 | timespec. | |
c4e6ff48 | 424 | |
2e8abfc1 CV |
425 | 2002-06-03 Pierre Humblet <pierre.humblet@ieee.org> |
426 | ||
427 | * sec_helper.cc (lookup_name): Suppress. | |
428 | * security.cc (alloc_sd): Remove logsrv argument. | |
429 | Remove two calls to lookup_name. | |
430 | (set_security_attribute): Remove logsrv argument. | |
431 | Remove logsrv argument in call to alloc_sd. | |
432 | (set_nt_attribute): Remove logsrv argument. | |
433 | Remove logsrv argument in call to set_security_attribute. | |
434 | (set_file_attribute): Remove logsrv argument. | |
435 | Remove logsrv argument in call to set_nt_attribute. | |
436 | (set_file_attribute): Remove logsrv argument. | |
437 | Remove logsrv argument in call to set_file_attribute. | |
438 | * syscalls.cc (chown_worker): Remove logserver argument in | |
439 | call to set_file_attribute. | |
440 | (chmod): Ditto. | |
441 | * shm.cc (shmget): Remove logsrv argument in call to alloc_sd. | |
442 | * uinfo.cc (internal_getlogin): Replace calls to | |
443 | lookup_name by call to LookupAccountName. | |
444 | * security.h: Remove logsrv in declarations of set_file_attribute | |
445 | and alloc_sd. Remove declaration of lookup_name. | |
446 | ||
f7a7cc90 CF |
447 | 2002-06-05 Christopher Faylor <cgf@redhat.com> |
448 | ||
449 | * child_info.h (CHILD_INFO_MAGIC): Oops. Revert previous change. gcc | |
450 | 3.1 bug? | |
451 | ||
784e340c CF |
452 | 2002-06-05 Christopher Faylor <cgf@redhat.com> |
453 | ||
454 | * child_info.h (CHILD_INFO_MAGIC): Update. | |
455 | ||
58fcd93a CF |
456 | 2002-06-05 Christopher Faylor <cgf@redhat.com> |
457 | ||
458 | * strace.cc (strace::hello): Set inited, when appropriate. | |
459 | ||
ee964e2f CF |
460 | 2002-06-05 Christopher Faylor <cgf@redhat.com> |
461 | ||
462 | * cygwin.din: Eliminate some newlib wrappers. | |
463 | * path.cc (get_devn): Only consider first 99 potential com devices. | |
464 | (get_device_number): Ditto. | |
465 | * times.cc (_times): Eliminate. | |
466 | (_times): Renamed from times(). | |
467 | ||
ea4e6ec8 CF |
468 | 2002-06-05 Christopher Faylor <cgf@redhat.com> |
469 | ||
470 | * dir.cc (rmdir): Streamline. Detect attempts to remove directories | |
471 | from "read-only" virtual devices. (Suggested by Pavel Tsekov) | |
46b941fc CF |
472 | * syscalls.cc (unlink): Detect attempts to remove directories from |
473 | "read-only" virtual devices. (From Pavel Tsekov) | |
ea4e6ec8 | 474 | |
2bb6b3e5 CF |
475 | 2002-06-05 Christopher Faylor <cgf@redhat.com> |
476 | ||
477 | * dtable.cc (handle_to_fn): Check error return value from NtQueryObject | |
478 | first before seeing if name buffer is NULL. | |
479 | ||
480 | * grp.cc (read_etc_group): Fix gcc warning regarding snprintf format. | |
481 | * passwd.cc (read_etc_passwd): Ditto. | |
482 | ||
e9259cb2 RC |
483 | 2002-04-18 Thomas Pfaff <tpfaff@gmx.net> |
484 | ||
485 | * thread.h (pthread::joiner): New member. | |
486 | * thread.cc (pthread::pthread): Initialize joiner to NULL | |
487 | (pthread::create): Increment of thread counter moved from | |
488 | __pthread_create to this location. | |
489 | (__pthread_create): Increment thread counter removed. | |
490 | (thread_init_wrapper): Set joiner to self when thread was created | |
491 | detached. | |
492 | (__pthread_exit): delete thread when it is detached and not | |
493 | joined. | |
494 | (__pthread_join): Check for deadlock and delete thread when it has | |
495 | terminated. | |
496 | (__pthread_detach): Set joiner to self when thread state | |
497 | changed to detached. | |
498 | ||
eceee297 CV |
499 | 2002-06-05 Corinna Vinschen <corinna@vinschen.de> |
500 | ||
501 | * grp.cc (read_etc_group): When emulating nonexisting group file on | |
502 | NT systems, read primary group SID from process token. Use that info | |
503 | to create correct group entry. On error or on 9x systems fallback | |
504 | to emulating Administrators group as before. | |
ae1ebb81 | 505 | * passwd.cc (read_etc_passwd): When emulating nonexisting passwd file |
46b941fc | 506 | on NT systems, read user and primary group SID from process token. |
ae1ebb81 CV |
507 | Use that info to create correct passwd entry. On error or on 9x |
508 | systems fallback to emulating user with Administrator user id and | |
509 | Administrators group as before. | |
eceee297 | 510 | |
38f39368 CV |
511 | 2002-06-05 Corinna Vinschen <corinna@vinschen.de> |
512 | ||
513 | * grp.cc (etc_group): Removed. | |
514 | (parse_grp): Make line parameter nonconst. Don't copy data into new | |
515 | allocated memory. Check for CR instead of LF to accomodate new | |
516 | read method. | |
517 | (add_grp_line): Make line parameter nonconst. | |
518 | (read_etc_group): Rearrange using new pwdgrp_read class. | |
519 | * passwd.cc (parse_pwd): Don't copy data into new allocated memory. | |
520 | Check for CR instead of LF to accomodate new read method. | |
521 | (read_etc_passwd): Rearrange using new pwdgrp_read class. | |
522 | * pwdgrp.h (pwdgrp_check::set_last_modified): Use different | |
523 | parameters. | |
524 | (class pwdgrp_read): New class for opening and reading passwd and | |
525 | group files. | |
526 | ||
ce006ffa CF |
527 | 2002-06-04 Christopher Faylor <cgf@redhat.com> |
528 | ||
529 | * dtable.cc (handle_to_fn): Attempt to handle "raw" accesses to remote | |
530 | shares. | |
531 | * path.cc (mount_info::conv_to_win32_path): Set flags to binary when | |
532 | mount entry is not found. | |
533 | (mount_info::set_flags_from_win32_path): Ditto. | |
534 | ||
147d2ab4 CF |
535 | 2002-06-04 Christopher Faylor <cgf@redhat.com> |
536 | ||
537 | * dtable.cc (handle_to_fn): Correct placement and length of name | |
ea4e6ec8 | 538 | buffer. (Suggested by Pavel Tsekov) |
147d2ab4 | 539 | |
e35f391f CF |
540 | 2002-06-04 Christopher Faylor <cgf@redhat.com> |
541 | ||
542 | Remove fcntl.h includes throughout. | |
543 | * fhandler.h: Move fcntl.h include here. | |
544 | (fhandler_base::set_flags): Accept supplied_bin argument. Make | |
545 | non-inlined. | |
546 | * dtable.cc (dtable::init_std_file_from_handle): Just use binmode from | |
547 | pc. | |
548 | (reset_to_open_binmode): Use set_flags. | |
549 | * cygwin.din (open): Avoid newlib wrapper. | |
550 | (read): Ditto. | |
551 | (unlink): Ditto. | |
552 | (write): Ditto. | |
553 | * fhandler.cc (fhandler_base::set_flags): Accept supplied_bin argument. | |
554 | Make binmode decisions here. | |
555 | (fhandler_base::open): Avoid using pc if it is NULL. Eliminate binmode | |
556 | logic. Just call set_flags with binmode argument. | |
557 | (fhandler_base::init): Call set_flags with binmode argument. | |
558 | * fhandler_clipboard.cc (fhandler_dev_clipboard::open): Ditto. | |
559 | * fhandler_console.cc (fhandler_console::open): Ditto. | |
560 | (fhandler_console::init): Force binary on open. | |
561 | * fhandler_disk_file.cc (fhandler_disk_file::open): Don't set binmode | |
562 | here. Let it happen in base class. | |
563 | * fhandler_dsp.cc (fhandler_dev_dsp::open): Force binmode open. Set | |
564 | return value appropriately if unable to open. | |
565 | * fhandler_proc.cc (fhandler_proc::open): Make sure flags are set | |
566 | before open_status. | |
567 | * fhandler_process.cc (fhandler_process::open): Ditto. | |
568 | * fhandler_registry.cc (fhandler_registry::open): Ditto. | |
569 | * fhandler_random.cc (fhandler_dev_random::fhandler_dev_random): Ditto. | |
570 | * fhandler_raw.cc (fhandler_dev_raw::open): Force O_BINARY by default. | |
571 | * fhandler_serial.cc (fhandler_serial::init): Ditto. | |
572 | * fhandler_tty.cc (fhandler_tty_slave::open): Ditto. | |
573 | (fhandler_pty_master::open): Ditto. | |
574 | * fhandler_virtual.cc (fhandler_virtual::open): Ditto. | |
575 | * fhandler_windows.cc (fhandler_windows::open): Ditto. | |
576 | * fhandler_zero.cc (fhandler_dev_zero::open): Ditto. | |
577 | * net.cc (fdsock): Ditto. | |
578 | * path.cc (path_conv::check): Avoid checking for executable extension | |
579 | when directory. (Suggested by Pavel Tsekov) | |
580 | (set_flags): Set PATH_TEXT explicitly, when appropriate. | |
581 | (mount_info::conv_to_win32_path): Use set_flags() to set path flags. | |
582 | * path.h (PATH_TEXT): New enum. | |
583 | (path_conv::binmode): Return appropriate constant based on binmode. | |
584 | * pipe.cc (make_pipe): Set binmode to O_TEXT xor O_BINARY. | |
585 | * syscalls.cc (setmode_helper): Make debugging message a little | |
586 | clearer. | |
587 | (setmode): Set binmode via set_flags. | |
588 | ||
4e138847 CV |
589 | 2002-06-04 Corinna Vinschen <corinna@vinschen.de> |
590 | ||
591 | * fhandler.h (class fhandler_socket): Add private method | |
592 | fixup_after_fork (bool, HANDLE). | |
593 | * fhandler_socket.cc (fhandler_socket::fixup_after_fork): Move | |
594 | functionality to new private method. Add closing parent socket | |
595 | if not called from dup(). Create method new calling private method | |
596 | with appropriate parameter. | |
597 | (fhandler_socket::fixup_after_exec): Call private method | |
598 | fixup_after_fork with appropriate parameter. | |
599 | (fhandler_socket::dup): Ditto. | |
600 | ||
601 | 2002-06-04 Corinna Vinschen <corinna@vinschen.de> | |
6bfca3cc CV |
602 | |
603 | * fhandler_dsp.cc (fhandler_dev_dsp::open): Set errno to EACCES if | |
604 | requested mode isn't supported. | |
605 | ||
e02f1e9c CF |
606 | 2002-06-03 Christopher Faylor <cgf@redhat.com> |
607 | ||
608 | * fhandler.cc (fhandler_base::open): Don't set binmode if already set. | |
609 | Don't check for file. Files should already be set. Report on binary | |
610 | mode for debugging. | |
611 | (fhandler_base::fhandler_base): Don't set default binmode here. That's | |
612 | for later. | |
613 | * fhandler_console.cc (fhandler_console::output_tcsetattr): Don't set | |
614 | binmode, ever, for console. | |
615 | * fhandler_disk_file.cc (fhandler_disk_file::open): Always set the | |
616 | binary mode to the value derived from mount table. | |
617 | * path.cc (mount_info::conv_to_win32_path): Default to binmode if path | |
618 | does not translate into anything in the mount table. | |
619 | ||
31b98a62 CV |
620 | 2002-06-03 Corinna Vinschen <corinna@vinschen.de> |
621 | ||
622 | * external.cc (cygwin_internal): Add CW_EXTRACT_DOMAIN_AND_USER | |
623 | handling to call extract_nt_dom_user() from applications. | |
624 | * include/sys/cygwin.h (cygwin_getinfo_types): Add | |
625 | CW_EXTRACT_DOMAIN_AND_USER. | |
626 | ||
b3c29731 CV |
627 | 2002-06-03 Corinna Vinschen <corinna@vinschen.de> |
628 | ||
629 | * syscalls.cc (stat64_to_stat32): Transform st_dev correctly. | |
630 | (fstat64): Add evaluating st_ino and st_dev. | |
631 | (stat_worker): Evaluate st_dev as 32 bit value. | |
632 | * include/cygwin/stat.h: Use new dev_t definition throughout. | |
633 | * include/cygwin/types.h: Define __dev16_t and __dev32_t. Define | |
634 | dev_t according to __CYGWIN_USE_BIG_TYPES__ setting. | |
635 | * include/sys/sysmacros.h: Define major, minor and makedev | |
636 | according to __CYGWIN_USE_BIG_TYPES__ setting. | |
637 | ||
656c3192 CV |
638 | 2002-06-03 Pierre Humblet <pierre.humblet@ieee.org> |
639 | ||
640 | * syscalls.cc (setegid32): Verify the correctness of the gid | |
641 | of the group returned by getgrgid32. | |
642 | ||
1eb934b7 CV |
643 | 2002-06-03 Pierre Humblet <pierre.humblet@ieee.org> |
644 | ||
645 | * security.cc (lsa2wchar): Suppressed. | |
646 | (get_lsa_srv_inf): Suppressed. | |
647 | (get_logon_server_and_user_domain): Suppressed. | |
648 | (get_logon_server): Essentially new. | |
649 | (get_user_groups): Add "domain" argument. Only lookup the | |
650 | designated server and use "domain" in LookupAccountName. | |
651 | (is_group_member): Simplify the arguments. | |
652 | (get_user_local_groups): Simplify the arguments. Do only a | |
653 | local lookup. Use "BUILTIN" and local domain in LookupAccountName. | |
654 | (get_user_primary_group). Only lookup the designated server. | |
655 | (get_group_sidlist): Remove logonserver argument. Do not lookup | |
656 | any server for the SYSTEM account. | |
657 | (create_token): Delete logonserver and call to get_logon_server. | |
658 | Adjust arguments of get_group_sidlist, see above. | |
659 | * security.h: Delete declaration of get_logon_server_and_user_domain | |
e35f391f | 660 | and add declaration of get_logon_server. |
1eb934b7 CV |
661 | * uinfo.cc (internal_get_login): Call get_logon_server instead of |
662 | get_logon_server_and_user_domain. | |
663 | ||
37be5a67 CF |
664 | 2002-06-02 Christopher Faylor <cgf@redhat.com> |
665 | ||
e35f391f CF |
666 | * dtable.cc (handle_to_fn): Use largest match for device. Correctly |
667 | (?) deal with remote drive weirdness. | |
37be5a67 | 668 | |
97478fe6 CF |
669 | 2002-06-02 Christopher Faylor <cgf@redhat.com> |
670 | ||
671 | * fhandler_disk_file.cc (fhandler_disk_file::fstat_by_name): Check | |
672 | specifically for non-existent file, first. | |
673 | (fhandler_disk_file::fstat): Perform fd open on files with funny | |
674 | characters. | |
675 | ||
47413f84 CF |
676 | 2002-06-02 Christopher January <chris@atomice.net> |
677 | ||
678 | * fhandler_process.cc (fhandler_process::open): Set fileid. | |
679 | ||
6b7cd251 CF |
680 | 2002-06-02 Christopher Faylor <cgf@redhat.com> |
681 | ||
682 | Remove unneeded sigproc.h includes throughout. | |
683 | * fhandler.h (fhandler_proc::fill_filebuf): Take a pinfo argument. | |
684 | * fhandler_proc.cc (fhandler_proc::get_proc_fhandler): Simplify search | |
685 | for given pid. | |
686 | (fhandler_proc::readdir): Assume that pid exists if it shows up in the | |
687 | winpid list. | |
688 | * fhandler_process.cc (fhandler_process::open): Simplify search for | |
689 | given pid. Call fill_filebuf with pinfo argument. | |
690 | (fhandler_process::fill_filebuf): Pass pinfo here and assume that it | |
691 | exists. | |
692 | * pinfo.h (pinfo::remember): Define differently if sigproc.h is not | |
693 | included. | |
694 | ||
695 | 2002-06-02 Christopher Faylor <cgf@redhat.com> | |
696 | ||
697 | * dll_init.cc (dll_list::detach): Don't run destructor on exit. | |
698 | ||
e065a187 CF |
699 | 2002-06-01 Christopher Faylor <cgf@redhat.com> |
700 | ||
701 | * fhandler.cc (fhandler_base::fstat): Move dev and ino calculation into | |
702 | caller. | |
703 | * syscalls.cc (stat_worker): Calculate dev and ino calculation here, if | |
704 | zero. | |
705 | * fhandler_proc.cc (fhandler_proc::fhandler_proc): Minor reorg for | |
706 | debugging. | |
707 | * fhandler_process.cc (fhandler_process::exists): Return 0 on | |
708 | nonexistence. | |
709 | (fhandler_process::fstat): Simplify pid logic. | |
710 | * fhandler_tape.cc (fhandler_dev_tape::fstat): Minor reformatting. | |
711 | ||
60abf1c4 CF |
712 | 2002-06-01 Christopher Faylor <cgf@redhat.com> |
713 | ||
714 | * path.cc (chdir): Don't allow cd'ing to a non-directory virtual path. | |
715 | ||
28af03fa CF |
716 | 2002-05-31 Christopher Faylor <cgf@redhat.com> |
717 | ||
718 | * fhandler_disk_file.cc (readdir): Move inode calculation into caller. | |
719 | (fhandler_cygdrive::readdir): Add "." and "..". | |
720 | * dir.cc (readdir): Move inode calculation here so that fhandler | |
721 | readdirs can benefit. | |
722 | ||
8e74c320 CF |
723 | 2002-05-31 Christopher Faylor <cgf@redhat.com> |
724 | ||
725 | * fhandler_console.cc (fhandler_console::open): Reinstate setting of | |
726 | flags. | |
727 | ||
30478f15 CF |
728 | * dtable.cc (dtable::init_std_file_from_handle): Default to using |
729 | binmode derived from path_conv, when required. | |
730 | * fhandler.h (fhandler_base::get_w_binary): Default to binmode if | |
731 | nothing else is specified. | |
732 | * fhandler.h (fhandler_base::get_r_binary): Ditto. | |
733 | ||
734 | * fhandler_disk_file.cc (fhandler_disk_file::fstat_by_handle): Work | |
735 | around g++ warning. | |
736 | ||
737 | * path.cc (path_conv::check): Remove a debugging statement. | |
738 | ||
de86e35b CF |
739 | 2002-05-31 Christopher Faylor <cgf@redhat.com> |
740 | ||
741 | * fhandler_console.cc (fhandler_console::open): Always default to | |
742 | binmode. | |
743 | (fhandler_console::write_normal): Don't honor binmode setting. There | |
744 | is already a termios setting for this. | |
745 | (fhandler_console::init): Correct argument order in init call. | |
746 | ||
8461f41e CF |
747 | 2002-05-31 Christopher Faylor <cgf@redhat.com> |
748 | ||
749 | * fhandler.cc (fhandler_base::open): Make default open mode == binmode. | |
750 | (fhandler_base::init): Set open flags based on derived binmode argument. | |
751 | ||
bcd0ed9f CF |
752 | 2002-05-31 Christopher Faylor <cgf@redhat.com> |
753 | ||
754 | * dll_init.cc (dll_list::init): Eliminate unneeded debugging statement. | |
755 | ||
18c04cc4 CF |
756 | 2002-05-31 Christopher Faylor <cgf@redhat.com> |
757 | ||
758 | * fhandler_proc.cc (fhandler_proc::readdir): Set errno when no more | |
759 | files. | |
760 | * fhandler_process.cc (fhandler_process::readdir): Ditto. | |
761 | * fhandler_registry.cc (fhandler_registry::readdir): Ditto. | |
762 | ||
69be001c CF |
763 | 2002-05-30 Christopher Faylor <cgf@redhat.com> |
764 | ||
765 | * path.cc (path_conv::check): Set fileattr to INVALID_FILE_ATTRIBUTES | |
766 | for nonexistent virtual device path. | |
767 | (chdir): Set correct errno when attempt is made to cd to nonexistent | |
768 | virtual device path. | |
769 | ||
5d8c7a56 CF |
770 | 2002-05-30 Christopher Faylor <cgf@redhat.com> |
771 | ||
772 | * fhandler_disk_file.cc (fhandler_disk_file::fstat): Always call | |
773 | fstat_by_name if fd is not opened to allow fstat_by_name to properly | |
774 | set errno. | |
775 | ||
d74eced5 CV |
776 | 2002-05-30 Corinna Vinschen <corinna@vinschen.de> |
777 | ||
778 | * autoload.cc: Replace autoload statments for ZwXXX by NtXXX. | |
779 | Drop ZwQuerySystemInformation since NtQuerySystemInformation was | |
780 | already available. | |
781 | * fhandler_proc.cc (format_proc_uptime): Replace call to | |
782 | ZwQuerySystemInformation by call to NtQuerySystemInformation. | |
783 | (format_proc_stat): Ditto. | |
784 | * fhandler_process.cc (format_process_stat): Replace call to | |
785 | ZwQueryInformationProcess by call to NtQueryInformationProcess. | |
786 | (get_process_state): Ditto. | |
787 | (get_mem_values): Ditto. Replace call to ZwQueryVirtualMemory by | |
788 | call to NtQueryVirtualMemory. | |
789 | * ntdll.h: Cleanup. Drop ZwQuerySystemInformation since | |
790 | NtQuerySystemInformation was already available. Replace declarations | |
791 | of ZwXXX functions by declarations of NtXXX. | |
792 | * pinfo.cc (winpids::enumNT): Replace call to ZwQuerySystemInformation | |
793 | by call to NtQuerySystemInformation. | |
794 | ||
5d8c7a56 CF |
795 | 2002-05-29 Christopher Faylor <cgf@redhat.com> |
796 | ||
797 | * fhandler.cc (binmode): Default to binmode when mode is not known. | |
798 | ||
186637a5 CF |
799 | 2002-05-29 Christopher Faylor <cgf@redhat.com> |
800 | ||
801 | * include/sys/cygwin.h (EXTERNAL_PINFO_VERSION): Reinstate. | |
802 | * external.cc (fillout_pinfo): Use it. | |
803 | ||
3a571063 CV |
804 | 2002-05-29 Corinna Vinschen <corinna@vinschen.de> |
805 | ||
806 | * external.cc (fillout_pinfo): Use new version define. | |
807 | * include/sys/cygwin.h (external_pinfo): Define | |
808 | EXTERNAL_PINFO_VERSION_16_BIT and EXTERNAL_PINFO_VERSION_32_BIT | |
809 | instead of just EXTERNAL_PINFO_VERSION. | |
810 | ||
9fef0139 CF |
811 | 2002-05-29 Christopher Faylor <cgf@redhat.com> |
812 | ||
813 | * external.cc (fillout_pinfo): Set new version field in external_pinfo | |
814 | structure. | |
815 | * include/sys/cygwin.h (external_pinfo): Replace strace_file with | |
816 | version field. | |
817 | ||
a8d7ae61 CV |
818 | 2002-05-29 Corinna Vinschen <corinna@vinschen.de> |
819 | ||
820 | Change internal uid datatype from __uid16_t to __uid32_t | |
821 | throughout. | |
822 | * cygwin.din: Export new symbols getpwuid32, getpwuid_r32, getuid32, | |
823 | geteuid32, setuid32, seteuid32. | |
824 | * passwd.cc (getpwuid32): New function. | |
825 | (getpwuid_r32): Ditto. | |
826 | * syscalls.cc (seteuid32): Ditto. | |
827 | (setuid32): Ditto. | |
828 | * uinfo.cc (getuid32): Ditto. | |
829 | (geteuid32): Ditto. | |
d4000bc4 | 830 | * winsup.h (uid16touid32): New macro, correct casting from __uid16_t |
a8d7ae61 CV |
831 | to __uid32_t. |
832 | (gid16togid32): Ditto fir gids. | |
833 | (getuid32): Declare. | |
834 | (geteuid32): Ditto. | |
835 | (getpwuid32): Ditto. | |
836 | * include/sys/cygwin.h (struct external_pinfo): Add members uid32 and | |
837 | gid32. | |
838 | ||
9854c44c CV |
839 | 2002-05-29 Corinna Vinschen <corinna@vinschen.de> |
840 | ||
841 | * include/cygwin/socket.h: Protect some symbols against multiple | |
842 | definition. | |
843 | * include/netinet/ip.h: Ditto. | |
844 | * include/netinet/tcp.h: Ditto. | |
845 | ||
846 | 2002-05-29 Wu Yongwei <adah@netstd.com> | |
847 | ||
848 | * include/netinet/ip.h: Replace by BSD derived version of the file. | |
849 | * include/netinet/tcp.h: Ditto. | |
850 | * include/netinet/udp.h: New file. | |
851 | * include/cygwin/ip.h: Remove. | |
852 | ||
cef69559 CF |
853 | 2002-05-29 Christopher Faylor <cgf@redhat.com> |
854 | ||
855 | * dtable.cc (dtable::init_std_file_from_handle): Attempt stronger | |
856 | detection of invalid handle. | |
857 | (handle_to_fn): Detect pathological condition where NT resets the | |
858 | buffer pointer to NULL on an invalid handle. | |
859 | ||
a761ad82 CF |
860 | 2002-05-28 Christopher Faylor <cgf@redhat.com> |
861 | ||
862 | * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Properly | |
863 | check for whether we should be opening the file to search for #! | |
654783b6 CF |
864 | characters. Set path_conv structure execability, too, when |
865 | appropriate. | |
a761ad82 | 866 | |
7ea70e99 CV |
867 | 2002-05-28 Corinna Vinschen <corinna@vinschen.de> |
868 | ||
869 | * security.cc (set_security_attribute): Call getegid32() instead of | |
870 | getegid(). | |
871 | * include/cygwin/grp.h: Declare getegid32(). | |
872 | ||
57196405 CV |
873 | 2002-05-28 Corinna Vinschen <corinna@vinschen.de> |
874 | ||
875 | Change internal gid datatype from __gid16_t to __gid32_t | |
876 | throughout. | |
877 | * cygwin.din: Export new symbols chown32, fchown32, getegid32, | |
878 | getgid32, getgrgid32, getgrnam32, getgroups32, initgroups32, lchown32, | |
879 | setgid32, setegid32, getgrent32. | |
880 | * grp.cc (grp32togrp16): New static function. | |
881 | (getgrgid32): New function. | |
882 | (getgrnam32): Ditto. | |
883 | (getgrent32): Ditto. | |
884 | (getgroups32): Change name of internal function from getgroups. | |
885 | (getgroups32): New function. | |
886 | (initgroups32): Ditto. | |
887 | * syscalls.cc (chown32): Ditto. | |
888 | (lchown32): Ditto. | |
889 | (fchown32): Ditto. | |
890 | (setegid32): Ditto. | |
891 | (setgid32): Ditto. | |
892 | * uinfo.cc (getgid32): Ditto. | |
893 | (getegid32): Ditto. | |
894 | * include/cygwin/grp.h: Remove declaration of getgrgid() and getgrnam(). | |
895 | Declare getgrgid32() and getgrnam32() instead. Declare getgid32(). | |
896 | ||
0c12979b CF |
897 | 2002-05-27 Christopher Faylor <cgf@redhat.com> |
898 | ||
899 | * autoload.cc (noload): Properly mask low order word for determining | |
900 | number of bytes to pop. | |
901 | ||
57e2ae68 CF |
902 | 2002-05-27 Christopher Faylor <cgf@redhat.com> |
903 | ||
904 | * fhandler_disk_file.cc (fhandler_disk_file::fstat): Minor logic | |
905 | cleanup. | |
906 | ||
2402700d CF |
907 | 2002-05-27 Christopher Faylor <cgf@redhat.com> |
908 | ||
909 | * autoload.cc (LoadFuncEx): Define via new LoadFuncEx2 macro. | |
910 | (LoadFuncEx2): Adapted from LoadFuncEx. Provides control of return | |
911 | value for nonexistent function. | |
912 | (NtQueryObject): Declare. | |
913 | (IsDebuggerPresent): Declare via LoadFuncEx2 and always return true if | |
914 | not available. | |
915 | * debug.h (being_debugged): Just rely on IsDebuggerPresent return | |
916 | value. | |
917 | * dtable.cc (handle_to_fn): New function. | |
918 | (dtable::init_std_file_from_handle): Attempt to derive std handle's | |
919 | name via handle_to_fn. | |
920 | (dtable::build_fhandler_from_name): Fill in what we can in path_conv | |
921 | structure when given a handle and path doesn't exist. | |
922 | * fhandler.cc (fhandler_base::open): Don't set the file pointer here. | |
923 | Use pc->exists () to determine if file exists rather than calling | |
924 | GetFileAttributes again. | |
925 | * fhandler.h (fhandler_base::exec_state_isknown): New method. | |
926 | (fhandler_base::fstat_helper): Add extra arguments to declaration. | |
927 | (fhandler_base::fstat_by_handle): Declare new method. | |
928 | (fhandler_base::fstat_by_name): Declare new method. | |
929 | * fhandler_disk_file (num_entries): Make __stdcall. | |
930 | (fhandler_base::fstat_by_handle): Define new method. | |
931 | (fhandler_base::fstat_by_name): Define new method. | |
932 | (fhandler_base:fstat): Call fstat_by_{handle,name} as appropriate. | |
933 | (fhandler_disk_file::fstat_helper): Accept extra arguments for filling | |
934 | out stat structure. Move handle or name specific stuff to new methods | |
935 | above. | |
936 | (fhandler_disk_file::open): Use real_path->exists rather than calling | |
937 | GetFileAttributes again. | |
938 | * ntdll.h (FILE_NAME_INFORMATION): Define new structure. | |
939 | (OBJECT_INFORMATION_CLASS): Partially define new enum. | |
940 | (OBJECT_NAME_INFORMATION): Define new structure. | |
941 | (NtQueryInformationFile): New declaration. | |
942 | (NtQueryObject): New declaration. | |
943 | * path.cc (path_conv::fillin): Define new method. | |
944 | * path.h (path_conv::fillin): Declare new method. | |
945 | (path_conv::drive_thpe): Rename from 'get_drive_type'. | |
946 | (path_conv::volser): Declare new method. | |
947 | (path_conv::volname): Declare new method. | |
948 | (path_conv::root_dir): Declare new method. | |
949 | * syscalls.cc (fstat64): Send real path_conv to fstat as second | |
950 | argument. | |
951 | ||
74b2f73e CV |
952 | 2002-05-24 Pierre Humblet <pierre.humblet@ieee.org> |
953 | ||
954 | * security.cc (lsa2str): New function. | |
955 | (get_priv_list): Call lsa2str instead of sys_wcstombs. | |
956 | ||
75bf2931 CV |
957 | 2002-05-22 Pierre Humblet <pierre.humblet@ieee.org> |
958 | ||
959 | * syscalls.cc (seteuid): Do not take allow_ntsec into account. | |
960 | Attempt to use an existing or new token even when the uid | |
961 | matches orig_uid, but the gid is not in the process token. | |
962 | Major reorganization after several incremental changes. | |
963 | (setegid): Do not take allow_ntsec into account. Minor | |
964 | reorganization after several incremental changes. | |
965 | ||
918a268c CF |
966 | 2002-05-26 Christopher Faylor <cgf@redhat.com> |
967 | ||
968 | * debug.h (being_debugged): New macro. | |
969 | * dtable.cc (dtable::extend): Use new macro. | |
970 | * exceptions.cc (try_to_debug): Ditto. | |
971 | * strace.cc (strace::hello): Only output debugging info when we think | |
972 | we're being debugged. | |
973 | ||
0cfbfc24 CF |
974 | 2002-05-25 Robert Collins <rbtcollins@hotmail.com> |
975 | ||
976 | * winsup.h: Remove duplicate declarations of malloc_lock and | |
977 | malloc_unlock. | |
978 | ||
d7b4a300 CF |
979 | 2002-05-24 Christopher Faylor <cgf@redhat.com> |
980 | ||
981 | Remove unneeded sync.h, where appropriate, throughout. | |
982 | Remove unneeded heap.h, where appropriate, throughout. | |
983 | Remove unneeded exceptions.h, where appropriate, throughout. | |
984 | Remove unneeded perprocess.h, where appropriate, throughout. | |
985 | ||
908f9b65 CV |
986 | 2002-05-22 Pierre Humblet <pierre.humblet@ieee.org> |
987 | ||
988 | * security.cc (create_token): Call __sec_user() instead of | |
989 | sec_user() to remove dependence on allow_ntsec. Verify that | |
990 | the returned sd is non-null. | |
991 | ||
a6247be9 RC |
992 | 2002-05-25 Robert Collins <rbtcollins@hotmail.com> |
993 | ||
994 | * gmon.c (fake_sbrk): Correctly return -1 on failed malloc's. | |
995 | ||
ff938546 CF |
996 | 2002-05-24 Christopher Faylor <cgf@redhat.com> |
997 | ||
998 | * dtable.cc (dtable::build_fhandler_from_name): Just pass posix path | |
999 | along to set_name via return_and_clear_normalized_path. | |
1000 | (dtable::build_fhandler): New method with const char * argument. | |
1001 | (dtable::reset_unix_path_name): Eliminate. | |
1002 | (dtable::dup_worker): Use correct build_fhandler method. | |
1003 | * mmap.cc (mmap_record::alloc_fh): Ditto. | |
1004 | * dtable.h (dtable::build_fhandler): New method. | |
1005 | (dtable::reset_unix_path_name): Eliminate. | |
1006 | * fhandler.cc (fhandler_base::set_name): Assume that unix_name has | |
1007 | already been cmalloced. | |
1008 | (fhandler_base::reset_unix_path_name): Eliminate. | |
1009 | (fhandler_base::~fhandler_base): Coercion for cfree. | |
1010 | * fhandler.h (fhandler_base::unix_path_name): Make const char *. | |
1011 | (fhandler_base::win32_path_name): Ditto. | |
1012 | (fhandler_base::reset_unix_path_name): Eliminate. | |
1013 | * fhandler_disk_file.cc (fhandler_cygdrive::set_drives): Accommodate | |
1014 | const char *ness of win32_path_name. | |
1015 | * fhandler_socket.cc (fhandler_socket::fstat): Accommodate new set_name | |
1016 | requirements. | |
1017 | * path.cc (path_conv::return_and_clear_normalized_path): New method. | |
1018 | (path_conv::clear_normalized_path): Eliminate. | |
1019 | (path_conv::~path_conv): Ditto. | |
1020 | (path_conv::check): Accommodate new build_fhandler method. | |
1021 | * path.h (path_conv::~path_conv): Eliminate. | |
1022 | (path_conv::clear_normalized_path): Ditto. | |
1023 | (path_conv::return_and_clear_normalized_path): Declare new method. | |
1024 | ||
b4bb31ad CF |
1025 | 2002-05-23 Christopher Faylor <cgf@redhat.com> |
1026 | ||
1027 | * path.cc (path_conv::check): Make sure any trailing path component is | |
1028 | part of potential normalized posix path. | |
1029 | ||
b2f338e9 CF |
1030 | 2002-05-23 Christopher Faylor <cgf@redhat.com> |
1031 | ||
1032 | * smallprint.c (__small_vsprintf): Implement '%o' after all these | |
1033 | years. | |
1034 | ||
fc240f58 CF |
1035 | 2002-05-22 Christopher Faylor <cgf@redhat.com> |
1036 | ||
1037 | * fhandler.h (fhandler_virtual::exists): Eliminate path argument. | |
1038 | (fhandler_proc::exists): Ditto. | |
1039 | (fhandler_registry::exists): Ditto. | |
1040 | (fhandler_process::exists): Ditto. | |
1041 | * fhandler_proc.cc (fhandler_proc::exists): Ditto. Use built-in name. | |
1042 | * fhandler_process.cc (fhandler_process::exists): Ditto. | |
1043 | (fstat): Ditto. | |
1044 | * fhandler_registry.cc (fhandler_registry::exists): Ditto. | |
1045 | (fhandler_registry::fstat): Ditto. | |
1046 | * fhandler_virtual.cc (fhandler_virtual::opendir): Ditto. | |
1047 | * path.cc (path_conv::check): Ditto. Add debugging. | |
1048 | ||
1049 | 2002-05-22 Christopher Faylor <cgf@redhat.com> | |
1050 | ||
1051 | * syscalls.cc (dup): Always call dup2 for error handling. | |
1052 | ||
1d2b71d6 CV |
1053 | 2002-05-22 Corinna Vinschen <corinna@vinschen.de> |
1054 | ||
1055 | * include/cygwin/types.h: Revert previous patch. | |
1056 | ||
36f86a55 CV |
1057 | 2002-05-22 Corinna Vinschen <corinna@vinschen.de> |
1058 | ||
1059 | * include/cygwin/types.h: Define pthread stuff only if _POSIX_THREADS | |
1060 | is defined. | |
1061 | ||
2d6ce5c2 CV |
1062 | 2002-05-19 Pierre Humblet <pierre.humblet@ieee.org> |
1063 | ||
fc240f58 | 1064 | * security.cc (open_local_policy): Initialize lsa to |
2d6ce5c2 CV |
1065 | INVALID_HANDLE_VALUE instead of NULL. |
1066 | (get_logon_server_and_user_domain): Test for INVALID_HANDLE_VALUE | |
1067 | instead of NULL. | |
1068 | (create_token): Both of the above. | |
1069 | ||
9ded8bd8 CF |
1070 | 2002-05-18 Christopher Faylor <cgf@redhat.com> |
1071 | ||
1072 | * fhandler_disk_file.cc (fhandler_disk_file::fstat): Make handling of | |
1073 | nlink consistent for remote files. | |
1074 | ||
2701126a CF |
1075 | 2002-05-18 Christopher Faylor <cgf@redhat.com> |
1076 | ||
1077 | * path.cc (path_conv::check): Always set executable bit for executable | |
1078 | extension. | |
1079 | ||
b05b7d84 CF |
1080 | 2002-05-17 Christopher Faylor <cgf@redhat.com> |
1081 | ||
1082 | * fhandler.cc (fhandler_base::lseek): Avoid calling SetFilePointer with | |
1083 | high order part of 64 bit address on OS's which do not support that | |
1084 | kind of operation. Otherwise Windows 95 will become confused. | |
1085 | ||
d6dc9825 CV |
1086 | 2002-05-16 Pierre Humblet <pierre.humblet@ieee.org> |
1087 | ||
1088 | * fhandler_raw.cc (fhandler_dev_raw::open): Replace set_errno() | |
1089 | by __seterrno_from_win_error(). | |
1090 | * security.cc (open_local_policy): Ditto. | |
1091 | (get_lsa_srv_inf): Ditto. | |
1092 | (get_user_groups): Ditto. | |
1093 | (get_user_primary_group): Ditto. | |
1094 | (create_token): Ditto. | |
1095 | (subauth): Ditto. | |
1096 | ||
35a89cbe CV |
1097 | 2002-05-17 Corinna Vinschen <corinna@vinschen.de> |
1098 | ||
1099 | * times.cc (utimes): Use FILE_WRITE_ATTRIBUTES even on 9x/Me when | |
1100 | opening file for writing timestamp. | |
1101 | * wincap.cc: Remove flag has_specific_access_rights. | |
1102 | * wincap.h: Ditto. | |
1103 | ||
ebbdc703 CV |
1104 | 2002-05-13 Pierre Humblet <pierre.humblet@ieee.org> |
1105 | ||
1106 | * syscalls.cc (seteuid): Set default dacl in process token. | |
1107 | Replace in-line code by call to verify_token(). | |
1108 | (setegid): Reverse change from 2002-01-21. Add call to | |
1109 | RevertToSelf and set primary group in impersonation token. | |
1110 | * security.cc (create_token): Store pgrpsid in token security | |
1111 | descriptor, except if it already appears in my_grps. | |
1112 | Use sec_acl() in place of get_dacl(). | |
1113 | (verify_token): Create from code in seteuid(), with tighter checks. | |
c2102631 | 1114 | (get_dacl): Deleted. |
ebbdc703 CV |
1115 | (get_group_sidlist): Add argument to indicate if pgrpsid is already |
1116 | in the groups. | |
1117 | * security.h: Define verify_token(). | |
1118 | * autoload.cc: Load GetKernelObjectSecurity(). | |
1119 | ||
feb7f1a9 CF |
1120 | 2002-05-13 Mark Bradshaw <bradshaw@staff.crosswalk.com> |
1121 | ||
1122 | * cygwin.din: Add strlcat and strlcpy. | |
1123 | * include/cygwin/version.h: Increment API minor version number. | |
1124 | ||
fc240f58 | 1125 | 2002-05-09 Pierre Humblet <pierre.humblet@ieee.org> |
043bc3e1 CV |
1126 | |
1127 | * shared.cc (__sec_user): Split into sec_acl() and call orig_sid(). | |
1128 | (sec_acl): Create from part of __sec_user(), except creator/owner. | |
1129 | * security.h: Define sec_acl() and MAX_DACL_LEN. | |
1130 | ||
c8b20196 CF |
1131 | 2002-05-12 Christopher Faylor <cgf@redhat.com> |
1132 | ||
1133 | * fhandler_disk_file.cc (fhandler_disk_file::open): Avoid using | |
1134 | O_DIROPEN when OS doesn't support it. Return proper errno in that | |
1135 | case. | |
1136 | ||
b4f8d31f CF |
1137 | 2002-05-12 Christopher Faylor <cgf@redhat.com> |
1138 | ||
56caca1d CF |
1139 | * syscalls.cc (_read): Change error to EBADF if attempt to read from a |
1140 | non-readable fd. | |
b4f8d31f | 1141 | |
29ee580d CF |
1142 | 2002-05-11 Christopher Faylor <cgf@redhat.com> |
1143 | ||
1144 | * fhandler.h (executable_states): For now, make dont_care_if_executable | |
1145 | equivalent to not_executable. | |
1146 | * sys/mount.h: Define MOUNT_NOTEXEC. | |
1147 | * path.h (fs_info): New class. | |
1148 | (path_conv): Move fs-specific fields to new 'fs' structure. | |
1149 | (path_conv::update_fs_info): Move to fs_info and rename to just 'update'. | |
1150 | * path.cc (fs_info::update): Ditto. Return 'true' if successful. | |
1151 | (fillout_mntent): Add ',noexec' to list of reported options. | |
1152 | ||
b84621d2 CF |
1153 | 2002-05-11 Christopher Faylor <cgf@redhat.com> |
1154 | ||
1155 | * fhandler_virtual.cc (fhandler_virtual::close): Quiet a compiler | |
1156 | warning. | |
1157 | ||
9ba913a5 CF |
1158 | 2002-05-10 Christopher January <chris@atomice.net> |
1159 | ||
1160 | * autoload.cc: Add dynamic load statements for | |
1161 | 'ZwQueryInformationProcess' and 'ZwQueryVirtualMemory'. | |
1162 | * fhandler.h: Change type of bufalloc and filesize members of | |
1163 | fhandler_virtual from int to size_t. Change type of position member | |
1164 | from __off32_t to __off64_t. Add new fileid member to fhandler_virtual | |
1165 | class. Make seekdir take an __off64_t argument. Make lseek take an | |
1166 | __off64_t argument. Add fill_filebuf method to fhandler_virtual. Add | |
1167 | fill_filebuf method to fhandler_proc. Add fill_filebuf method to | |
1168 | fhandler_registry. Add fill_filebuf method to fhandler_process. Add | |
1169 | saved_pid and saved_p members to fhandler_process. | |
1170 | * fhandler_proc.cc (proc_listing_array): Add 'loadavg', 'meminfo', and 'stat'. | |
1171 | (proc_fhandlers array): Ditto. | |
1172 | (fhandler_proc::open): Use fill_filebuf to flesh out the file contents. | |
1173 | (fhandler_proc::fill_filebuf): New method. | |
1174 | (fhandler_proc::format_proc_meminfo): Ditto. | |
1175 | (fhandler_proc::format_proc_stat): Ditto. | |
1176 | (fhandler_proc::format_proc_uptime): Ditto. | |
1177 | * fhandler_process.cc (process_listing): Add 'stat' and 'statm'. | |
1178 | (fhandler_process::fstat): Find the _pinfo structure for the process | |
1179 | named in the filename. Return ENOENT if the process is no longer | |
1180 | around. Set the gid and uid fields of the stat structure. | |
1181 | (fhandler_process::open): Store pid and pointer to _pinfo structure in | |
1182 | saved_pid and saved_p respectively. Use fill_filebuf to flesh out file | |
1183 | contents. | |
1184 | (fhandler_proc::fill_filebuf): New method. | |
1185 | (format_process_stat): New function. | |
1186 | (format_process_status): Ditto. | |
1187 | (format_process_statm): Ditto. | |
1188 | (get_process_state): Ditto. | |
1189 | (get_mem_values): Ditto. | |
1190 | * fhandler_registry.cc (fhandler_registry::seekdir): Change argument | |
1191 | type from __off32_t to __off64_t. | |
1192 | (fhandler_registry::fill_filebuf): New method. | |
1193 | * fhandler_virtual.cc (fhandler_virtual::seekdir): Change argument type | |
1194 | from __off32_t to __off64_t. | |
1195 | (fhandler_virtual::lseek): Ditto. | |
1196 | (fhandler_virtual::fill_filebuf): New method. | |
1197 | (fhandler_virtual::fhandler_virtual): Initialise fileid to -1. | |
1198 | * wincap.cc: Set flag has_process_io_counters appropriately. | |
1199 | * wincap.h: Add flag has_process_io_counters. | |
1200 | ||
1201 | 2002-05-09 Christopher Faylor <cgf@redhat.com> | |
f561f644 CF |
1202 | |
1203 | * syscalls.cc (_write): Change error to EBADF if attempt to write to a | |
56caca1d | 1204 | non-writeable fd. |
f561f644 | 1205 | |
6327de5f CV |
1206 | 2002-05-08 Corinna Vinschen <corinna@vinschen.de> |
1207 | ||
1208 | * cygheap.h (class cygheap_user): Add member `orig_psid'. | |
1209 | Add method `orig_sid()'. | |
1210 | * cygheap.cc (cygheap_user::set_sid): Maintain orig_psid. | |
1211 | ||
795b46cf CV |
1212 | 2002-04-28 Norbert Schulze <norbert.schulze@web.de> |
1213 | ||
1214 | * localtime.cc (tzsetwall): Use wildabbr if generated timezone name | |
1215 | length < 3. | |
1216 | ||
a9917779 CV |
1217 | 2002-05-05 Pierre Humblet <pierre.humblet@ieee.org> |
1218 | ||
1219 | * spawn.cc (spawn_guts): Move call to set_process_privilege() | |
1220 | to load_registry_hive(). | |
1221 | * registry.cc (load_registry_hive): ditto. | |
1222 | * fork.cc (fork_parent): Call sec_user_nih() only once. | |
1223 | ||
1224 | 2002-05-04 Christopher January <chris@atomice.net> | |
13ee3618 CF |
1225 | |
1226 | * path.h (path_conv::path_conv): Initialise normalized_path to NULL. | |
1227 | ||
8761c1dc CF |
1228 | 2002-05-03 Christopher Faylor <cgf@redhat.com> |
1229 | ||
1230 | * net.cc (getdomainname): Change second argument of getdomainname to | |
1231 | size_t. | |
1232 | ||
1233 | 2002-05-03 Christopher January <chris@atomice.net> | |
1234 | ||
1235 | * fhandler_proc.cc (proc_listing): Add '.' and '..' to directory | |
1236 | listing. | |
1237 | (fhandler_proc::open): Change use of mode to flags. If the file does | |
1238 | not exist already, fail with EROFS if O_CREAT flag is set. Change | |
1239 | EROFS error to EACCES error when writing to a file. Use cmalloc to | |
1240 | allocate memory for filebuf. | |
1241 | (fhandler_proc::close): Use cfree to free filebuf. | |
1242 | (fhandler_proc::get_proc_fhandler): Properly detect attempts to access | |
1243 | unknown subdir. | |
1244 | * fhandler_process.cc (process_listing): Add '.' and '..' to directory | |
1245 | listing. | |
1246 | (fhandler_process::open): Use cmalloc to allocate memory for filebuf. | |
1247 | (fhandler_process::close): Use cfree to free filebuf. | |
1248 | * fhandler_registry.cc (registry_listing): Add . and '..' to directory | |
1249 | listing. | |
1250 | (fhandler_registry::open): Move check for open for writing before | |
1251 | open_key. Use cmalloc to allocate memory for filebuf. | |
1252 | (fhandler_registry::close): Use cfree to free filebuf. | |
1253 | (fhandler_registry::telldir): Use lower 16 bits of __d_position as | |
1254 | position in directory. | |
1255 | (fhandler_registry::seekdir): Ditto. | |
1256 | * fhandler_virtual.cc (fhandler_virtual::write): Change EROFS error to | |
1257 | EACCES error. | |
1258 | (fhandler_virtual::open): Set the NOHANDLE flag. | |
1259 | (fhandler_virtual::dup): Add call to fhandler_base::dup. Allocate | |
1260 | child's filebuf using cmalloc. Copy filebuf from parent to child. | |
1261 | (fhandler_virtual::close): Use cfree to free filebuf. | |
1262 | (fhandler_virtual::~fhandler_virtual): Ditto. | |
1263 | (from Chris Faylor <cgf@redhat.com>). | |
1264 | (fhandler_registry::readdir): Add support for '.' and '..' files in | |
1265 | subdirectories of /proc/registry. | |
1266 | * path.cc (path_conv::check): Do not return ENOENT if a file is not | |
1267 | found in /proc. | |
1268 | ||
335c87f9 CF |
1269 | 2002-05-02 Christopher Faylor <cgf@redhat.com> |
1270 | ||
1271 | * fhandler_proc.cc (fhandler_proc::fstat): Use fhandler name rather | |
1272 | than path_conv name. | |
1273 | (fhandler_proc::open): Ditto. | |
1274 | * fhandler_process.cc (fhandler_process::fstat): Use fhandler name | |
1275 | rather than path_conv name. | |
1276 | (fhandler_process::open): Ditto. | |
1277 | * fhandler_registry.cc (fhandler_registry::fstat): Use fhandler name | |
1278 | rather than path_conv name. | |
1279 | (fhandler_registry::open): Ditto. | |
1280 | * path.cc (path_conv::check): Don't copy posix path when virtual. | |
1281 | (mount_info::conv_to_win32_path): Don't zero string when isproc. Just | |
1282 | derive normal windows path. | |
1283 | ||
1284 | * path.h (path_conv::clear_normalized_path): Declare new method. | |
1285 | * path.cc (path_conv::clear_normalized_path): Define new method. | |
1286 | * dtable.cc (build_fhandler_from_name): Clear normalized path when | |
1287 | finished to conserve space. | |
1288 | ||
3bb7eb44 CF |
1289 | 2002-05-02 Christopher Faylor <cgf@redhat.com> |
1290 | ||
1291 | * fhandler_proc.cc (fhandler_proc::fstat): Prime with information from | |
1292 | fhandler_base::fstat. Use defines rather than constants for permission | |
1293 | settings. | |
1294 | ||
d055ecb0 CV |
1295 | 2002-04-30 Eric Blake <ebb9@email.byu.edu> |
1296 | ||
1297 | * path.cc (hash_path_name): Improve hash function strength. | |
1298 | ||
37143995 RC |
1299 | 2002-05-02 Robert Collins <rbtcollins@hotmail.com> |
1300 | ||
1301 | * thread.cc (__pthread_cond_dowait): Fix a race on signalling from a | |
1302 | thread woken by the same condition variable it's signalling on. Thanks | |
1303 | to Michael Beach for the report and test case. | |
1304 | ||
291be307 CF |
1305 | 2002-05-02 Christopher Faylor <cgf@redhat.com> |
1306 | ||
1307 | * path.h (pathconv_arg): Add PC_POSIX. | |
1308 | (path_conv): Add normalized_path field. | |
1309 | * path.cc (path_conv::~path_conv): New destructor. | |
1310 | (path_conv::check): Set normalized_path, where appropriate. | |
1311 | * dtable.cc (build_fhandler_from_name): Use normalized path from | |
1312 | path_conv. | |
1313 | * syscalls.cc (chroot): Ditto. | |
1314 | ||
1315 | * cygheap.h: Remove path_prefix_p declaration. | |
1316 | ||
1317 | 2002-02-26 Christopher January <chris@atomice.net> | |
1318 | Christopher Faylor <cgf@redhat.com> (minor fixups) | |
1319 | ||
1320 | * Makefile.in: Add fhandler_proc.o, fhandler_registry.o, | |
1321 | fhandler_process.o and fhandler_virtual.o. | |
1322 | * dtable.cc (dtable::build_fhandler): Add entries for FH_PROC, | |
1323 | FH_REGISTRY and FH_PROCESS. Set unix_name to the normalized posix | |
1324 | path. | |
1325 | * fhandler.h: Add constants for FH_PROC, FH_REGISTRY and FH_PROCESS. | |
1326 | Add class declarations for fhandler_virtual, fhandler_proc, | |
1327 | fhandler_registry and fhandler_virtual. Update fhandler_union | |
1328 | accordingly. | |
1329 | * fhandler_proc.cc: New file. Add implementation for fhandler_proc. | |
1330 | * fhandler_virtual.cc: New file. Add implementation for | |
1331 | fhandler_virtual. | |
1332 | * fhandler_process.cc: New file. Add implementation for | |
1333 | fhandler_process. | |
1334 | * fhandler_registry.cc: New file. Add implementation for | |
1335 | fhandler_registry. | |
8761c1dc CF |
1336 | * path.cc (isproc): New macro. |
1337 | (isvirtual_dev): Ditto. | |
291be307 CF |
1338 | * path.cc (path_conv::check): Add check for virtual devices. |
1339 | * path.cc (mount_info::conv_to_win32_path): Convert paths in /proc to | |
1340 | empty Win32 paths. | |
1341 | * path.cc (chdir): Replace check for FH_CYGDRIVE with more generic | |
1342 | isvirtual_dev macro. Force setting of posix path for virtual | |
1343 | fhandlers. | |
8761c1dc | 1344 | * path.h (path_prefix_p): Declare. |
291be307 CF |
1345 | |
1346 | ||
fee93846 CF |
1347 | Wed May 1 16:06:02 2002 Jason Tishler <jason@tishler.net> |
1348 | ||
1349 | * include/cygwin/types.h: Include <sys/sysmacros.h>. | |
1350 | ||
9b15f5fa CV |
1351 | Wed Apr 17 11:27:04 2002 Jason Tishler <jason@tishler.net> |
1352 | ||
1353 | * security.cc (get_lsa_srv_inf): Prevent extraneous backslashes for | |
1354 | the NT Domain case. | |
1355 | ||
4deace13 CV |
1356 | 2002-04-12 Corinna Vinschen <corinna@vinschen.de> |
1357 | ||
1358 | * net.cc (cygwin_accept): Set socket type for accepted socket. | |
1359 | (socketpair): Set socket type for both sockets. | |
1360 | ||
1361 | 2002-04-12 Egor Duda <deo@logos-m.ru> | |
1362 | ||
291be307 | 1363 | * fhandler.h (class fhandler_socket): New member to store socket type. |
4deace13 CV |
1364 | (fhandler_socket::get_socket_type): Access it. |
1365 | (fhandler_socket::set_socket_type): Ditto. | |
1366 | * net.cc (cygwin_socket): Store socket type. | |
1367 | (cygwin_connect): Disable security checks for connectionless sockets. | |
1368 | (cygwin_accept): Ditto. | |
1369 | ||
dbe67a81 CF |
1370 | 2002-04-09 Mark Bradshaw <bradshaw@staff.crosswalk.com> |
1371 | ||
1372 | * cygwin.din: Add strptime. | |
1373 | * include/cygwin/version.h: Increment API version number. | |
1374 | ||
464b3e80 CV |
1375 | 2002-04-09 Corinna Vinschen <corinna@vinschen.de> |
1376 | ||
1377 | * fork.cc (fork_child): Call fixup_mmaps_after_fork() somewhat earlier. | |
1378 | ||
d78bda7b CV |
1379 | 2002-04-09 Corinna Vinschen <corinna@vinschen.de> |
1380 | ||
1381 | * fhandler.cc (fhandler_base::open): Set read-only bit in | |
1382 | file_attributes when adequate. | |
1383 | ||
8996623b CF |
1384 | 2002-03-28 Christopher Faylor <cgf@redhat.com> |
1385 | ||
1386 | * times.cc (gettimeofday): Fix typo in previous patch. | |
1387 | ||
7d7524e5 CF |
1388 | 2002-03-27 Wu Yongwei <adah@netstd.com> |
1389 | ||
1390 | * times.cc (gettimeofday): Revert to setting timezone info if tz != | |
1391 | NULL. | |
1392 | ||
2f3126f6 CF |
1393 | 2002-03-21 Christopher Faylor <cgf@redhat.com> |
1394 | ||
1395 | * fhandler_disk_file.cc (fhandler_disk_file::fstat_helper): Always set | |
1396 | st_[ug]id to value derived from get_file_attributes. | |
1397 | ||
45d2ea8a CF |
1398 | 2002-03-21 Christopher Faylor <cgf@redhat.com> |
1399 | ||
1400 | * spawn.cc (find_exec): Return input if file not found. | |
1401 | ||
99dbafac CV |
1402 | 2002-03-19 Boris Schaeling <boriss@web.de> |
1403 | ||
291be307 | 1404 | * poll.cc (poll): Add support for invalid descriptors. |
99dbafac | 1405 | |
b0359971 RC |
1406 | 2002-03-15 Robert Collins <rbtcollins@hotmail.com> |
1407 | ||
1408 | * fhandler.h (fhandler_termios::lseek): Override lseek. | |
1409 | * fhandler_termios.cc (fhandler_termios::lseek): Implement this. | |
1410 | ||
59a2339f CF |
1411 | 2002-03-15 Christopher Faylor <cgf@redhat.com> |
1412 | ||
1413 | * cygserver.cc: Include stdlib.h for exit declaration. | |
1414 | * threaded_queue.cc: Ditto. | |
1415 | ||
ca175377 CF |
1416 | 2002-03-15 Christopher Faylor <cgf@redhat.com> |
1417 | ||
1418 | * pinfo.cc (pinfo::init): Use PID_ALLPIDS flag to control when a | |
1419 | redirected block should be marked as nonexistent. | |
1420 | (winpids::add): Use PID_ALLPIDS when looking for all pids. | |
1421 | * cygwin.h (PID_ALLPIDS): New enum element. | |
1422 | ||
d78bda7b | 1423 | 2002-03-15 Corinna Vinschen <corinna@vinschen.de> |
2f263187 | 1424 | |
291be307 | 1425 | * glob.c (stat32_to_STAT): New function. |
2f263187 CV |
1426 | (g_lstat): Call user space functions always with 32 bit struct stat |
1427 | as a workaround. | |
1428 | (g_stat): Ditto. | |
1429 | * include/glob.h (struct glob): Don't prototype function pointers | |
1430 | when compiling Cygwin. | |
1431 | ||
4af6d4a9 CF |
1432 | 2002-03-14 Christopher Faylor <cgf@redhat.com> |
1433 | ||
1434 | * pinfo.cc (pinfo::init): Properly handle execed process stub when | |
1435 | PID_NOREDIR is specified. | |
1436 | ||
6ea9c716 CV |
1437 | 2002-03-13 Boris Schaeling <boriss@web.de> |
1438 | ||
e10c087b CF |
1439 | * poll.cc (poll): Remove variable open_fds. Rearrange and add code to |
1440 | fix settings of revents. | |
6ea9c716 | 1441 | |
d78bda7b | 1442 | 2002-03-13 Corinna Vinschen <corinna@vinschen.de> |
bbe09139 CV |
1443 | |
1444 | * mmap.cc (mmap_record::map_map): Return -1 if VirtualProtect fails. | |
1445 | (list::erase): New method with no argument. Erase latest record | |
1446 | added. | |
1447 | (mmap64): Fail if map_map() fails. | |
1448 | ||
d78bda7b | 1449 | 2002-03-12 Corinna Vinschen <corinna@vinschen.de> |
cb4589f4 CV |
1450 | |
1451 | * sysconf.cc (sysconf): Fix condition. | |
1452 | ||
d78bda7b | 1453 | 2002-03-11 Corinna Vinschen <corinna@vinschen.de> |
2817e0dc CV |
1454 | |
1455 | * mmap.cc (msync): Check area given by addr and len for being a | |
1456 | contigeous mmap'd region. | |
1457 | ||
d78bda7b | 1458 | 2002-03-11 Corinna Vinschen <corinna@vinschen.de> |
713fb38b CV |
1459 | |
1460 | * fork.cc (fork_child): Call fixup_mmaps_after_fork() before | |
1461 | closing parent process handle. Call fixup_mmaps_after_fork() | |
1462 | with parent process handle as parameter. | |
1463 | * mmap.cc (mmap_record::access): New method. | |
1464 | (fixup_mmaps_after_fork): Take process handle as parameter. | |
1465 | In case of FILE_MAP_COPY access, copy valid memory regions to child. | |
1466 | * pinfo.h (fixup_mmaps_after_fork): Change prototype accordingly. | |
1467 | ||
d78bda7b | 1468 | 2002-03-07 Corinna Vinschen <corinna@vinschen.de> |
c8c3824d CV |
1469 | |
1470 | * autoload.cc (NetGetDCName): Add symbol. | |
1471 | (NetServerEnum): Remove symbol. | |
1472 | * security.cc (get_lsa_srv_inf): Call NetGetDCName() instead of | |
1473 | NetServerEnum() since it's faster. Don't call it at all if machine | |
1474 | is not a domain member. | |
1475 | ||
9420d2b8 CF |
1476 | 2002-03-06 Christopher Faylor <cgf@redhat.com> |
1477 | ||
1478 | * path.cc (normalize_posix_path): Avoid runs of '.'s > 2. | |
1479 | ||
07a21bce CF |
1480 | 2002-03-05 Christopher Faylor <cgf@redhat.com> |
1481 | ||
1482 | * errno.cc: Change EPERM associated text to "Operation not permitted" | |
1483 | throughout. | |
1484 | ||
eeac69d8 CF |
1485 | 2002-03-05 Christopher Faylor <cgf@redhat.com> |
1486 | ||
1487 | * fhandler_socket.cc (fhandler_socket::close): Respond to signals while | |
1488 | looping, waiting for socket to close. Superstitiously clear last error | |
1489 | when WSAEWOULDBLOCK. | |
1490 | ||
241a7c5a RC |
1491 | 2002-03-05 Robert Collins <rbtcollins@hotmail.com> |
1492 | ||
291be307 | 1493 | * cygserver_transport_pipes.cc (transport_layer_pipes::transport_layer_pipes): |
241a7c5a RC |
1494 | Always init - until static members work correctly. |
1495 | * shm.cc (shmget): Initialize the security descriptor - thanks Corinna! | |
291be307 | 1496 | * include/sys/ipc.h: Make the ipc control constants partitioned off from the sem |
241a7c5a RC |
1497 | control constants. |
1498 | ||
ad2864f4 CV |
1499 | 2002-03-04 Christian Lestrade <christian.lestrade@free.fr> |
1500 | ||
1501 | * include/sys/termios.h: Define _POSIX_VDISABLE. Define CCEQ macro. | |
1502 | * fhandler_termios.cc: Include <sys/termios.h>. | |
1503 | (line_edit): Recognize disabled c_cc[] chars. Ignore VDISCARD when | |
1504 | not in ICANON mode. | |
1505 | ||
59149930 CV |
1506 | 2002-03-04 Dmitry Timoshkov <dmitry@baikal.ru> |
1507 | ||
1508 | * syscalls.cc (truncate64): Use ftruncate64 directly to not lose | |
1509 | upper 32 bits. | |
1510 | ||
7c3617cc RC |
1511 | 2002-03-04 Robert Collins <rbtcollins@hotmail.com> |
1512 | ||
1513 | * cygserver_shm.cc (delete_shmnode): New function. | |
1514 | (client_request_shm::serve): Use it. | |
1515 | ||
038c71f1 RC |
1516 | 2002-03-04 Robert Collins <rbtcollins@hotmail.com> |
1517 | ||
1518 | * cygserver_shm.cc (client_request_shm::serve): Implement SHM_DETACH. | |
1519 | * shm.cc (shmdt): Implement. | |
1520 | ||
67be0adb RC |
1521 | 2002-03-04 Robert Collins <rbtcollins@hotmail.com> |
1522 | ||
1523 | * cygserver_shm.cc: Run indent. | |
1524 | (deleted_head): New global for storing shm id's pending deletion. | |
1525 | (client_request_shm::serve): Return ENOSYS for invalid request types. | |
1526 | Implement SHM_DEL - delete a shm id. | |
1527 | * cygserver_shm.h (SHM_DEL): New type value. | |
1528 | * shm.cc (delete_inprocess_shmds): New function, does what it's name implies. | |
1529 | (shmctl): Implement shm_rmid control type. | |
1530 | ||
74c3173a RC |
1531 | 2002-03-04 Robert Collins <rbtcollins@hotmail.com> |
1532 | ||
1533 | * Makefile.in (install): Remove install-bin to allow make install to work. | |
1534 | ||
009314a4 RC |
1535 | 2002-03-03 Robert Collins <rbtcollins@hotmail.com> |
1536 | ||
1537 | * shm.cc (shmat): Prevent a compile error. | |
1538 | (shmdt): Set errno as this function is incomplete. | |
1539 | ||
e7729287 CF |
1540 | 2002-02-28 Christopher Faylor <cgf@redhat.com> |
1541 | ||
1542 | * times.cc: Remove if 0'd code. Clean up slightly. | |
1543 | ||
f449bfef RC |
1544 | 2002-02-28 Robert Collins <rbtcollins@hotmail.com> |
1545 | ||
1546 | * Merged cygwin_daemon into head minus the new shm and ipc exports. | |
1547 | ||
1548 | 2002-02-28 Robert Collins <rbtcollins@hotmail.com> | |
1549 | ||
1550 | * fhandler_tty.cc (fhandler_tty_slave::open): More debugging. | |
1551 | (fhandler_tty_slave::read): Fix printf type for the handle. | |
1552 | * tty.cc (tty::common_init): Add a FIXME for security. | |
1553 | ||
1554 | 2002-01-29 Robert Collins <rbtcollins@hotmail.com> | |
1555 | ||
1556 | * Makefile.in (OBJS): Remove duplicate localtime.o. | |
1557 | ||
1558 | 2002-01-17 Robert Collins <rbtcollins@hotmail.com> | |
1559 | ||
291be307 | 1560 | * cygserver.cc (check_and_dup_handle): Consolidate the two variants for |
f449bfef RC |
1561 | simplicity. |
1562 | Add Some basic debug output. | |
1563 | (client_request_attach_tty::serve): Use the new debug_printf for clarity. | |
1564 | Mark the duplicated handles as inheritable - fixup_after_fork() doesn't reopen | |
1565 | tty's. | |
1566 | ||
1567 | 2002-01-16 Robert Collins <rbtcollins@hotmail.com> | |
1568 | ||
1569 | * cygserver.cc (transport): Correct scope. | |
1570 | (client_request_attach_tty::serve): Add more debug information. | |
1571 | Fix erroneous use of transport instead of conn. | |
1572 | * cygserver_transport_pipes.cc (transport_layer_pipes::close): More debug. | |
1573 | (transport_layer_pipes::read): Ditto. | |
1574 | (transport_layer_pipes::write): Ditto. | |
1575 | (transport_layer_pipes::impersonate_client): Ditto. | |
1576 | ||
1577 | Mon Oct 8 7:41:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1578 | ||
1579 | * cygserver.cc (server_request::process): Rename client_request_shm_get to | |
1580 | client_request_shm. | |
1581 | * cygserver_process.cc (process_cache::add): Rename to add_task. | |
1582 | Use process_cleanup instead of process_request. | |
1583 | (process_cache::remove_process): New method. | |
1584 | (process::process): Initialize new members. | |
1585 | (process::~process): New member. | |
1586 | (process::cleanup): New method. | |
1587 | (process::add_cleanup_routine): New method. | |
1588 | (process_request::process): Rename to process_cleanup. | |
1589 | Call the process object's cleanup method and then delete it. | |
1590 | (process_process_param::request_loop): Remove the signalling process. | |
1591 | * cygserver_shm.cc: Globally rename client_request_shm_get to client_request_shm. | |
1592 | (client_request_shm_get::serve): Handle attach request counting. | |
1593 | * cygserver_shm.h: Globally rename client_request_shm_get to client_request_shm. | |
1594 | (class shm_cleanup): New class. | |
1595 | * shm.cc: Globally rename client_request_shm_get to client_request_shm. | |
1596 | (client_request_shm::client_request_shm): New constructor for attach requests. | |
1597 | (shmat): Use it. | |
291be307 | 1598 | * include/cygwin/cygserver_process.h (class process_request): Rename to |
f449bfef RC |
1599 | process_cleanup. |
1600 | (class cleanup_routine): New class. | |
1601 | (class process): New members and methods to allow calling back when the process | |
1602 | terminates. | |
1603 | ||
1604 | Thu Oct 4 14:12:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1605 | * cygserver.cc (request_loop): Make static. | |
1606 | (main): Use new cache constructor syntax. | |
1607 | Start cache worker threads. | |
1608 | Cleanup the cache at shutdown. | |
1609 | * cygserver_process.cc: Run indent. | |
1610 | (process_cache::process_cache): Add a trigger to use when adding a process. | |
1611 | (process_cache::process): Move process_entry to process. | |
1612 | Insert at the end of the list. | |
1613 | Trigger the request loop when new process's inserted. | |
1614 | (process_cache::process_requests): Do it. | |
1615 | (process_cache::add): New method. | |
1616 | (process_cache::handle_snapshot): New method. | |
1617 | (process::process): Merge in the process_entry fields. | |
1618 | (process::handle): Make a stub function. | |
1619 | (process::exit_code): New method. | |
1620 | (process_request::process): New method. | |
1621 | (process_process_param::request_loop): New method. | |
1622 | * cygserver_shm.cc: New header dependency - threaded_queue.h. | |
1623 | * threaded_queue.cc (threaded_queue::cleanup): Clearer messages. | |
1624 | (queue_process_param::stop): Short spinlock on interruptible threads. | |
1625 | * threaded_queue.h (class threaded_queue): New constructor. | |
1626 | * include/cygwin/cygserver_process.h (process_request): New class. | |
1627 | (process_entry): Remove. | |
1628 | (process): Merge in process_entry. | |
1629 | (process_cache): Inherit from threaded_queue. | |
1630 | ||
1631 | Tue Oct 2 23:24:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1632 | ||
1633 | * cygserver.cc (class server_process_param): Use new constructor syntax. | |
1634 | * cygserver_process.cc (process_cache::~process_cache): New function. | |
1635 | * threaded_queue.cc: Define condition debug_printf. | |
1636 | Run indent. | |
1637 | (threaded_queue::cleanup): Move queue_process_param guts to a method. | |
1638 | (threaded_queue::process_requests): Ditto. | |
1639 | (queue_process_param::queue_process_param): New method. | |
1640 | (queue_process_param::~queue_process_param): Ditto. | |
1641 | (queue_process_param::start): Ditto. | |
1642 | (queue_process_param::stop): Ditto. | |
291be307 | 1643 | * threaded_queue.h (class queue_process_param): Add support for |
f449bfef RC |
1644 | interruptible request loops. |
1645 | * cygwin/include/cygwin/cygserver_process.h (class process_cache): Add | |
1646 | destructor. | |
1647 | ||
1648 | Tue Oct 2 23:24:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1649 | ||
1650 | * cygserver_client.cc: New flag allow_daemon to disable the daemon completely. | |
1651 | (cygserver_request): Check it. | |
1652 | (cygserver_init): Ditto. | |
1653 | * environ.cc (parse_thing): Add (no)daemon option. | |
1654 | ||
1655 | Tue Oct 2 23:00:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1656 | ||
1657 | * shm.cc: Update to handle include changes from HEAD. | |
1658 | ||
1659 | Tue Oct 2 16:06:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1660 | ||
291be307 | 1661 | * Makefile.in: Remove cygserver_shm.o from cygwin1.dll. |
f449bfef RC |
1662 | Rename cygserver_shm_outside.o to cygserver_shm.o. |
1663 | * cygserver.cc (server_request::process): Use the new client_request | |
1664 | constructor. | |
1665 | * cygserver_client.cc: Remove the #ifdef's stubs for the server method | |
1666 | within cygwin. | |
1667 | (client_request_attach_tty::client_request_attach_tty): Use the new | |
1668 | client_request constructor. | |
1669 | (client_request_shutdown::client_request_shutdown): Ditto. | |
1670 | (client_request::client_request): Ditto. | |
291be307 | 1671 | * cygserver_shm.cc (client_request_shm_get::serve): Remove the |
f449bfef RC |
1672 | #ifdef'd stub for in-cygwin builds. |
1673 | (client_request_shm_get::client_request_shm_get): Use the new | |
1674 | client_request constructor, and remove the in-cygwin variants. | |
1675 | * cygserver_shm.h (class client_request_shm_get): #ifndef test the | |
1676 | serve method - it's only used in cygserver. | |
1677 | * shm.cc (client_request_shm_get::client_request_shm_get): New function. | |
1678 | * include/cygwin/cygserver.h (request_header): New constructor. | |
291be307 | 1679 | (class client_request): Use it. |
f449bfef RC |
1680 | New constructor accepting the header size. |
1681 | #ifndef test the server method - it's only used within cygserver. | |
1682 | (client_request_get_version): #ifdef test the server method. | |
1683 | (client_request_shutdown): Ditto. | |
1684 | (client_request_attach_tty): Ditto. | |
1685 | ||
1686 | Tue Oct 2 9:57:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1687 | ||
1688 | * Makefile.in: add threaded_queue.o to cygserver.exe. | |
1689 | * cygserver.cc: Include threaded_queue.h | |
1690 | (class server_request): Inherit from queue_request. | |
1691 | (class server_process_param): Inherit from queue_process_param. | |
1692 | (class server_request_queue): Inherit from threaded_queue. | |
1693 | (request_loop): Adjust for new types. | |
291be307 | 1694 | (server_request_queue::process_requests): Remove guts to |
f449bfef RC |
1695 | threaded_queue::process_requests. |
1696 | (server_request::server_request): Adjust for new types. | |
1697 | (worker_function): Delete. | |
1698 | (server_request_queue::create_workers): Delete. | |
1699 | (server_request_queue::cleanup): Delete. | |
1700 | (server_request_queue::add): Move guts to threaded_queue::add. | |
1701 | * threaded_queue.cc: New file. | |
1702 | * threaded_queue.h: New file. | |
1703 | ||
1704 | Mon Oct 1 12:38:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1705 | ||
1706 | * cygserver.cc (client_request::serve): New function. | |
1707 | * cygserver_process.cc: Inlude <pthread.h> for pthread_once. | |
1708 | (process_cache::process_cache): Initialise a crtiical section for write access. | |
291be307 | 1709 | (process_cache::process): Use the critical section. Also add missing entries to |
f449bfef RC |
1710 | the cache. |
1711 | (do_process_init): New function to initalise class process static variables. | |
291be307 | 1712 | (process::process): Ensure that the process access critical section is |
f449bfef RC |
1713 | initialised. |
1714 | (process::handle): Close the handle of old process's when they have terminated | |
1715 | and we are returning the handle for a process with the same pid. | |
1716 | * cygserver_shm.cc: Run indent. | |
1717 | Include cygserver_process.h to allow process cache functionality. | |
1718 | (client_request_shm_get::serve): New parameter for process cache support. | |
1719 | Use the process cache, not OpenProcess to get a handle to the originating process. | |
1720 | Fix a handle leak with token_handle. | |
291be307 | 1721 | * cygserver_shm.h (class client_request_shm_get): Update ::serve for process |
f449bfef RC |
1722 | cache support. |
1723 | * cygserver_transport_pipes.cc: Redefine debug_printf to be conditional on DEBUG. | |
291be307 | 1724 | * include/cygwin/cygserver.h: Do not implement client_request::serve in the |
f449bfef | 1725 | header. |
291be307 CF |
1726 | * include/cygwin/cygserver_process.h (class process_cache): Add a write access |
1727 | critical section to prevent races when requests from a multithreaded | |
f449bfef RC |
1728 | application arrive. |
1729 | ||
1730 | Sun Sep 30 23:41:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1731 | ||
1732 | * Makefile.in: Add cygserver_process.o to cygserver.exe. | |
1733 | * cygserver.cc: Include signal.h and cygwin_version.h. | |
1734 | Define debug_printf as a macro. | |
1735 | Define DEBUG to a value. | |
1736 | (client_request_attach_tty::serve): Add beginning of process cache support. | |
1737 | Change from #ifdef DEBUG to work with new DEBUG style. | |
1738 | (client_request_get_version::serve): Add beginning of process cache support. | |
1739 | (class server_request): New prototype for support of process cache. | |
1740 | (class queue_process_param): New class to allow request loop threading. | |
1741 | (class server_request_queue): Add beginning of process cache support. | |
1742 | Allow request loop threading. | |
1743 | (request_loop): Thread function for request loops. | |
1744 | (server_request_queue::process_requests): Initiator for threaded request loops. | |
1745 | (client_request_shutdown::serve): Add beginning of process cache support. | |
1746 | (server_request::server_request): Ditto. | |
291be307 | 1747 | (server_request::process): Use debug_printf. Add beginning of process cache |
f449bfef RC |
1748 | support. |
1749 | (server_request_queue::cleanup): Kill off any request loop threads. | |
1750 | (server_request_queue::add): Add beginning of process cache support. | |
1751 | (handle_signal): Trigger a shutdown. | |
1752 | (main): Print out some useful info at startup - version, date time. | |
1753 | Add process cache support. | |
1754 | Spawn a separate thread for the transport request loop, thus allowing concurrent | |
1755 | support for multiple transports. | |
291be307 | 1756 | * cygserver_client.cc (client_request_get_version::serve): Add process cache |
f449bfef RC |
1757 | support. |
1758 | (client_request_attach_tty::serve): Add process cache support. | |
1759 | (client_request_shutdown::serve): Add process cache support. | |
1760 | * cygsserver_process.cc: New file with the process cache support. | |
1761 | * cygserver_shm.cc: Redefine debug_printf to allow conditional output. | |
1762 | * cygwin.din: Export shmdt(). | |
1763 | * shm.cc: Run indent. | |
1764 | Update FIXME's. | |
1765 | (shmdt): New function. | |
1766 | * include/cygwin/cygserver.h (class client_request): Add process cache support. | |
1767 | (class client_request_get_version): Ditto. | |
1768 | (class client_request_shutdown): Ditto. | |
1769 | (class client_request_attach_tty): Ditto. | |
1770 | * include/cygwin/cygserver_process.h: New header for process cache support. | |
1771 | ||
1772 | Sun Sep 30 8:52:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1773 | ||
1774 | * include/cygwin/cygserver_transport.h: Add copyright header. | |
1775 | * include/cygwin/cygserver_transport_pipes.h: Ditto. | |
1776 | * include/cygwin/cygserver_transport_sockets.h: Ditto. | |
1777 | ||
1778 | Sat Sep 29 20:40:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1779 | ||
1780 | * Makefile.in: Add cygserver_transport_sockets.o to DLL_OFILES. | |
1781 | Add cygserver_transport_sockets_outside.o to cygserver.exe. | |
1782 | * cygserver.cc: Include new include files. | |
1783 | * cygserver_client.cc: Ditto. | |
1784 | * cygserver_shm.h: No need to include <sys/socket.h> now. | |
1785 | * cygerver_transport.cc: Include new include files. | |
1786 | (transport_layer_base::transport_layer_base): Strip back to a stub. | |
1787 | (transport_layer_base::listen): Ditto. | |
1788 | (transport_layer_base::accept): Ditto. | |
1789 | (transport_layer_base::close): Ditto. | |
1790 | (transport_layer_base::read): Ditto. | |
1791 | (transport_layer_base::write): Ditto. | |
1792 | (transport_layer_base::connect): Ditto. | |
291be307 | 1793 | * cygserver_transport_pipes.cc: Include new header |
f449bfef RC |
1794 | "cygwin/cygserver_transport_pipes.h". |
1795 | * cygserver_transport_sockets.cc: New file. | |
1796 | * dcrt0.cc: No need to include <sys/socket.h> now. | |
1797 | * fhandler_tty.cc: Ditto. | |
1798 | * tty.cc: Ditto. | |
1799 | * include/cygwin/cygserver_transport.h: Strip the base class to a stub. | |
1800 | Remove the cygserver_transport_pipes class. | |
1801 | * include/cygwin/cygserver_transport_pipes.h: New file. | |
1802 | * include/cygwin/cygserver_transport_sockets.h: New file. | |
1803 | ||
1804 | Tue Sep 25 16:22:00 2001 Robert Collins <rbtcollins@hotmail.com> | |
1805 | ||
1806 | * autoload.cc: Add dynamic load statement for 'ImpersonateNamedPipeClient'. | |
1807 | * Makefile.in: Add new object files, and build instructions for cygserver.exe. | |
1808 | * cygwin.din: Export ftok, shmat, shmctl and shmget. | |
1809 | * dcrt0.cc: Additional includes for cygserver support. | |
1810 | (dll_crt0_1): Initialise the cygserver client. | |
1811 | * fhandler.h (fhandler_tty): New method cygserver_attach_tty. | |
1812 | * fhandler_tty.cc: Additional includes for cygserver support. | |
1813 | (fhandler_tty_slave::open): Attempt to use the cygserver when obtaining | |
1814 | handles from the parent process. On failure or 9x use the current method. | |
1815 | (fhandler_tty_slave::cygserver_attach_tty): New function. | |
1816 | * fork.cc (fork_child): Fixup shm memory mapped areas. | |
1817 | * pinfo.h: Declare fixup_shms_after_fork(). | |
1818 | * security.h: Declare alloc_sd(). | |
1819 | * tty.cc: Additonal includes to support cygserver. | |
1820 | (tty::common_init): Don't allow others to open us if the cygserver is running. | |
1821 | * winsup.h: Declare cygserver_running. | |
1822 | * cygserver.cc: New file. | |
1823 | * cygserver_client.cc: New file. | |
1824 | * cygserver_shm.cc: New file. | |
1825 | * cygserver_shm.h: New file. | |
1826 | * cygserver_transport.cc: New file. | |
1827 | * cygserver_transport_pipes.cc: New file. | |
1828 | * ipc.cc: New file. | |
1829 | * shm.cc: New file. | |
1830 | * include/cygwin/cygserver.h: New file. | |
1831 | * include/cygwin/cygserver_transport.h: New file. | |
1832 | * include/sys/ipc.h: New file. | |
1833 | * include/sys/shm.h: New file. | |
1834 | ||
062401c9 RC |
1835 | 2002-02-28 Robert Collins <rbtcollins@hotmail.com> |
1836 | ||
1837 | * thread.cc (semaphore::TryWait): Set errno as required by posix 1003.1. | |
1838 | (__sem_wait): Ditto. | |
1839 | (__sem_trywait): Ditto. | |
1840 | ||
d1f50ae5 CF |
1841 | 2002-02-27 Christopher Faylor <cgf@redhat.com> |
1842 | ||
1843 | * include/cygwin/version.h: Bump DLL minor number. | |
1844 | ||
acb56175 CV |
1845 | 2002-02-23 Corinna Vinschen <corinna@vinschen.de> |
1846 | ||
1847 | * cygwin.din (fstat64): New symbol. | |
1848 | (ftruncate64): Ditto. | |
1849 | (lseek64): Ditto. | |
1850 | (lstat64): Ditto. | |
1851 | (mmap64): Ditto. | |
1852 | (seekdir64): Ditto. | |
1853 | (stat64): Ditto. | |
1854 | (telldir64): Ditto. | |
1855 | (truncate64): Ditto. | |
1856 | * dir.cc (telldir64): New function. | |
1857 | (telldir): Call telldir64(). | |
1858 | (seekdir64): New function. | |
1859 | (seekdir): Call seekdir64(). | |
1860 | * fhandler.h: Redefine all methods using __off32_t to use __off64_t. | |
1861 | * fhandler.cc: Use __off64_t and struct __stat64 throughout. | |
1862 | * fhandler_clipboard.cc: Ditto. | |
1863 | * fhandler_disk_file.cc: Ditto. | |
1864 | * fhandler_dsp.cc: Ditto. | |
1865 | * fhandler_floppy.cc: Ditto. | |
1866 | * fhandler_mem.cc: Ditto. | |
1867 | * fhandler_random.cc: Ditto. | |
1868 | * fhandler_socket.cc: Ditto. | |
1869 | * fhandler_tape.cc: Ditto. | |
1870 | * fhandler_zero.cc: Ditto. | |
1871 | * pipe.cc: Ditto. | |
1872 | * glob.c: Ditto, call lstat64 and stat64 in Cygwin. | |
1873 | * mmap.cc: Use __off64_t throughout. | |
1874 | (mmap64): New function. | |
1875 | * sec_acl.cc (acl_worker): Use struct __stat64, call stat64 and lstat64. | |
1876 | * syscalls.cc (lseek64): New function. | |
1877 | (stat64_to_stat32): Ditto. | |
1878 | (fstat64): Ditto. | |
1879 | (stat64): Ditto. | |
1880 | (lstat64): Ditto. | |
1881 | (ftruncate64): Ditto. | |
1882 | (truncate64): Ditto. | |
1883 | (_fstat): Call fstat64. | |
1884 | (_stat): Call stat64. | |
1885 | (cygwin_lstat): Rename to avoid declaration problem. Call lstat64. | |
1886 | (stat_worker): Use struct __stat64. | |
1887 | (access): Ditto. | |
1888 | (ftruncate): Call ftruncate64. | |
1889 | (truncate): Call truncate64. | |
1890 | * wincap.cc: Set flag has_64bit_file_access appropriately. | |
1891 | * wincap.h: Add flag has_64bit_file_access. | |
1892 | * winsup.h (ILLEGAL_SEEK): Define as __off64_t. | |
1893 | (stat_dev): Declare using struct __stat64. | |
1894 | (stat_worker): Ditto. | |
1895 | * include/cygwin/stat.h (struct __stat32): Define if compiling Cygwin. | |
1896 | (struct __stat64): Ditto. | |
1897 | (struct stat): Revert definition with explicitly sized datatypes. | |
1898 | Eliminate sized field names. | |
1899 | * include/cygwin/types.h (blksize_t): New type. | |
1900 | (__blkcnt32_t): Ditto. | |
1901 | (__blkcnt64_t): Ditto. | |
1902 | (blkcnt_t): Ditto. | |
1903 | ||
083abe54 CF |
1904 | 2002-02-22 Christopher Faylor <cgf@redhat.com> |
1905 | ||
1906 | * sync.h (new_muto): Just accept an argument which denotes the name of | |
1907 | the muto. Use this argument to construct static storage. | |
1908 | * cygheap.cc (cygheap_init): Reflect above change. | |
1909 | * exceptions.cc (events_init): Ditto. | |
1910 | * malloc.cc (malloc_init): Ditto. | |
1911 | * path.cc (cwdstuff::init): Ditto. | |
1912 | * cygheap.h (cwdstuff): Change name of lock element to make it less | |
1913 | generic. | |
1914 | * path.cc (cwdstuff::get_hash): Ditto. | |
1915 | (cwdstuff::get_initial): Ditto. | |
1916 | (cwdstuff::set): Ditto. | |
1917 | (cwdstuff::get): Ditto. | |
1918 | * sigproc.cc (proc_subproc): Ditto. | |
1919 | ||
1920 | * debug.cc (lock_debug): Change to method. Use method rather than | |
1921 | macro throughout. | |
1922 | ||
1923 | * tty.h (tty_min::kill_pgrp): Declare new method. | |
1924 | * fhandler_termios.cc (tty_min::kill_pgrp): New method. | |
1925 | (fhandler_termios::line_edit): Use new method for killing process. | |
1926 | * dcrt0.cc (do_exit): Ditto. | |
1927 | ||
1928 | * dtable.cc (dtable::get_debugger_info): New method for inheriting | |
1929 | dtable info from a debugger. | |
1930 | * tty.cc (tty_init): Attempt to grab file handle info from parent | |
1931 | debugger, if appropriate. | |
1932 | ||
1933 | # dtable.cc (dtable::stdio_init): Make this a method. | |
1934 | (dtable::init_std_file_from_handle): Don't set fd unless it's not open. | |
1935 | (dtable::build_fhandler_from_name): Move name setting to | |
1936 | dtable::build_fhandler. | |
1937 | (dtable::build_fhandler): Add win32 name parameter. | |
1938 | * dcrt0.cc (dll_crt0_1): Change to use dtable stdio_init. | |
1939 | * dtable.h (dtable): Reflect build_fhandler parameter change. | |
1940 | * mmap.cc (mmap_record::alloc_fh): Don't set name parameter in | |
1941 | build_fhandler. | |
1942 | * net.cc (fdsock): Remove set_name call since it is now handled by | |
1943 | build_fhandler. | |
1944 | ||
1945 | * sigproc.cc (proc_subproc): Release muto as early as possible. | |
1946 | ||
a6790c5f CV |
1947 | 2001-02-22 Corinna Vinschen <corinna@vinschen.de> |
1948 | ||
1949 | * smallprint.c (rn): Allow long long values. | |
1950 | (__small_vsprintf): Add 'D', 'U' and 'X' formats for long long | |
1951 | parameters. | |
1952 | ||
aa6df8d7 CF |
1953 | 2002-02-19 Christopher Faylor <cgf@redhat.com> |
1954 | ||
1955 | * fhandler.cc (fhandler_base::puts_readahead): Remove default parameter | |
1956 | setting. Newer gcc's complain about this. | |
1957 | (fhandler_base::set_readahead_valid): Ditto. | |
1958 | * fhandler_dsp.cc (Audio::open): Ditto. | |
1959 | (fhandler_dev_dsp::open): Ditto. | |
1960 | ||
cecb74ae CF |
1961 | 2002-02-19 Christopher Faylor <cgf@redhat.com> |
1962 | ||
1963 | * fork.cc (fork_parent): Use sec_user_nih to control process/thread | |
1964 | inheritance/permission. | |
1965 | * spawn.cc (spawn_guts): Ditto. | |
1966 | * security.cc (create_token): Initialize token so that it is not tested | |
1967 | for bogus value later. Use sec_user to control process/thread | |
1968 | creation. | |
1969 | * security.h (__sec_user): Rename declaration from sec_user. | |
1970 | (sec_user_nih): Declare here as inline function wrapper for __sec_user. | |
1971 | (sec_user): Ditto. | |
1972 | * sigproc.cc (czombies): Allocate a character array for zombies to | |
1973 | avoid constructor overhead | |
1974 | (extremely hackish, I know). | |
1975 | (cpchildren): Ditto. | |
1976 | (pchildren): New define. | |
1977 | (zombies): Ditto. | |
1978 | (getsem): Use sec_user_nih to control semaphore inheritance/permission. | |
1979 | ||
2bd22312 CF |
1980 | 2002-02-16 Christopher Faylor <cgf@redhat.com> |
1981 | ||
1982 | * times.cc (hires::prime): Restore thread priority on failure | |
1983 | condition. | |
1984 | ||
1985 | * uinfo.cc (uinfo_init): Use more robust method for determining if | |
1986 | process was invoked from a non-cygwin process. | |
1987 | ||
1988 | * sync.h (muto::init): Eliminate "inheritance" parameter. | |
1989 | (new_muto): Reflect removal of parameter. | |
1990 | * sync.cc (muto::init): Ditto. | |
1991 | * cygheap.cc (cygheap_init): Ditto. | |
1992 | * debug.cc (threadname_init): Ditto. | |
1993 | * exceptions.cc (events_init): Ditto. | |
1994 | * malloc.cc (malloc_init): Ditto. | |
1995 | * path.cc (cwdstuff::init): Ditto. | |
1996 | * sigproc.cc (sigproc_init): Ditto. | |
1997 | ||
4c761646 CF |
1998 | * grp.cc (group_lock): Use different method for locking with static |
1999 | member. | |
2bd22312 | 2000 | (read_etc_group): REALLY ensure that read lock mutex is released. |
4c761646 CF |
2001 | * passwd.cc (passwd_lock): Use different method for locking with static |
2002 | member. | |
2003 | (read_etc_passwd): REALLY ensure that read lock mutex is released. | |
2bd22312 CF |
2004 | |
2005 | * shared.cc (sec_user): Correct reversed inheritance test. | |
2006 | ||
60b68f0d CF |
2007 | 2002-02-15 Christopher Faylor <cgf@redhat.com> |
2008 | ||
2009 | * hires.h (hires::usecs): Rename from utime. Accept an argument. | |
2010 | * strace.cc (strace::microseconds): Use hires class for calculating | |
2011 | times. | |
2012 | * sync.h (new_muto): Use NO_COPY explicitly in declaration. | |
2013 | * times.cc (gettimeofday): Reflect change in usecs argument. | |
2014 | (hires::usecs): Ditto. Changed name from utime. | |
2015 | * winsup.h (NO_COPY): Add nocommon attribute to force setting aside | |
2016 | space for variable. | |
2017 | * regcomp.c (REQUIRE): Add a void cast to bypass a warning. | |
2018 | ||
dce87b21 CF |
2019 | 2002-02-15 Christopher Faylor <cgf@redhat.com> |
2020 | ||
2021 | * hires.h: New file. | |
2022 | * times.cc (gettimeofday): Use hires class for calculating current time. | |
2023 | (hires::prime): New method. | |
2024 | (hires::utime): Ditto. | |
2025 | ||
3d456520 CF |
2026 | 2002-02-14 Christopher Faylor <cgf@redhat.com> |
2027 | ||
2028 | * include/sys/cygwin.h (cygwin_getinfo_types): New CW_STRACE_ACTIVE. | |
2029 | * external.cc (cygwin_internal): Handle CW_STRACE_ACTIVE. | |
2030 | ||
907dc7d0 CF |
2031 | 2002-02-14 Christopher Faylor <cgf@redhat.com> |
2032 | ||
2033 | * exceptions.cc (unused_sig_wrapper): Eliminate unused parameter to | |
2034 | asm. | |
2035 | * external.cc (cygwin_internal): Change CW_STRACE_ON to | |
2036 | CW_STRACE_TOGGLE. | |
2037 | * strace.cc (strace::hello): Toggle strace on and off. | |
2038 | * sync.cc (muto::init): Renamed from constructor. | |
2039 | * sync.h (muto::new): Delete. | |
2040 | (muto::delete): Ditto. | |
2041 | (new_muto): Simplify. Use muto.init for nearly everything. | |
2042 | * uinfo.cc (uinfo_init): Avoid closing a NULL handle. | |
2043 | * include/sys/cygwin.h (cygwin_getinfo_types): Rename CW_STRACE_OFF to | |
2044 | CW_STRACE_TOGGLE. Delete CW_STRACE_OFF. | |
2045 | * include/sys/strace.h (strace): Add "inited" field. | |
2046 | ||
4753a17b CV |
2047 | 2001-02-12 Corinna Vinschen <corinna@vinschen.de> |
2048 | ||
2049 | * include/cygwin/acl.h: Fix definition of aclent_t. | |
2050 | ||
909acaf6 CF |
2051 | 2002-02-10 Christopher Faylor <cgf@redhat.com> |
2052 | ||
2053 | * Makefile.in (DLL_OFILES): Consolidate object files. | |
2054 | ||
de4e0d30 CV |
2055 | 2002-02-10 Corinna Vinschen <corinna@vinschen.de> |
2056 | ||
b31c68c4 CV |
2057 | * child_info.h, cygheap.h, fhandler_clipboard.cc, fhandler_dsp.cc, |
2058 | fhandler_floppy.cc, fhandler_mem.cc, fhandler_random.cc, | |
2059 | fhandler_tape.cc, fhandler_zero.cc, grp.cc, mmap.cc, passwd.cc, | |
2060 | pinfo.cc, pinfo.h, pipe.cc, sec_acl.cc, sec_helper.cc, security.cc, | |
2061 | security.h, thread.h, uinfo.cc, include/cygwin/acl.h: Fix copyright. | |
2062 | ||
2063 | 2002-02-10 Corinna Vinschen <corinna@vinschen.de> | |
2064 | ||
2065 | * child_info.h, cygheap.h, dcrt0.cc, dir.cc, fhandler.cc, fhandler.h, | |
de4e0d30 CV |
2066 | fhandler_clipboard.cc, fhandler_disk_file.cc, fhandler_dsp.cc, |
2067 | fhandler_floppy.cc, fhandler_mem.cc, fhandler_random.cc, | |
2068 | fhandler_tape.cc, fhandler_zero.cc, grp.cc, mmap.cc, passwd.cc, | |
2069 | pinfo.cc, pinfo.h, pipe.cc, sec_acl.cc, sec_helper.cc, security.cc, | |
b31c68c4 | 2070 | security.h, spawn.cc, syscalls.cc, thread.h, uinfo.cc, winsup.h: |
de4e0d30 CV |
2071 | Change usage of uid_t to __uid16_t, gid_t to __gid16_t and |
2072 | off_t to __off32_t throughout. Use INVALID_UID, INVALID_GID and | |
2073 | INVALID_SEEK instead casting -1 to the appropriate type. | |
2074 | * winsup.h: Define INVALID_UID, INVALID_GID and INVALID_SEEK. | |
2075 | * include/cygwin/acl.h: Define internal __aclent16_t and __aclent32_t | |
2076 | types. Don't declare acl functions when compiling Cygwin. | |
2077 | * include/cygwin/grp.h: Declare getgrgid() and getgrnam() with | |
2078 | correct types for internal usage. | |
2079 | ||
39b553b8 CV |
2080 | 2002-02-10 Corinna Vinschen <corinna@vinschen.de> |
2081 | ||
2082 | Patch suggested by Pierre A. Humblet <Pierre.Humblet@ieee.org>: | |
2083 | * uinfo.cc (internal_getlogin): Try evaluating user by SID even if | |
2084 | ntsec is off. | |
2085 | (uinfo_init): Set primary group even if ntsec is off. | |
2086 | ||
52296b85 CV |
2087 | 2002-02-09 Corinna Vinschen <corinna@vinschen.de> |
2088 | ||
2089 | * include/cygwin/grp.h: New file. | |
2090 | * include/cygwin/stat.h: Ditto. | |
2091 | * include/cygwin/types.h: Add definitions for __off32_t, | |
2092 | __off64_t, off_t, __uid16_t, __uid32_t, uid_t, __gid16_t, | |
2093 | __gid32_t and gid_t. | |
2094 | * include/sys/cygwin.h: Use correct uid and gid types. | |
2095 | ||
ff86860b CV |
2096 | 2002-02-09 Corinna Vinschen <corinna@vinschen.de> |
2097 | ||
2098 | * dtable.cc (dtable::dup2): Revert previous patch. | |
2099 | * fhandler.h: Ditto. | |
2100 | (fhandler_socket::recv): Define new method. | |
2101 | (fhandler_socket::send): Ditto. | |
2102 | * fhandler_socket.cc (fhandler_socket::recv): New method. | |
2103 | (fhandler_socket::send): Ditto. | |
2104 | (fhandler_socket::read): Call fhandler_socket::recv() now. | |
2105 | (fhandler_socket::write): Call fhandler_socket::send() now. | |
2106 | * net.cc (class wsock_event): Move definition to wsock_event.h. | |
2107 | (fdsock): Revert previous patch. | |
2108 | (cygwin_recv): Move implementation to fhandler_socket::recv(). | |
2109 | (cygwin_send): Move implementation to fhandler_socket::send(). | |
2110 | * wsock_event.h: New file. | |
2111 | ||
d0672acc CV |
2112 | 2002-02-06 Alexander Gottwald <Alexander.Gottwald@s1999.tuchemnitz.de> |
2113 | ||
2114 | * net.cc (get_2k_ifconf): Create interface entries for tokenring cards. | |
2115 | ||
fae28904 CV |
2116 | 2002-02-08 Corinna Vinschen <corinna@vinschen.de> |
2117 | ||
2118 | * dtable.cc (dtable::dup2): Store fd for fhandler_socket. | |
2119 | * fhandler.h (fhandler_base::set_fd): New virtual method. | |
2120 | (fhandler_base::get_fd): Ditto. | |
2121 | (fhandler_socket::set_fd): Ditto. | |
2122 | (fhandler_socket::get_fd): Ditto. | |
2123 | * fhandler_socket.cc (fhandler_socket::read): Call cygwin_recv instead | |
2124 | of native Winsock recv. | |
2125 | (fhandler_socket::write): Call cygwin_send instead of native Winsock | |
2126 | send. | |
2127 | * net.cc (fdsock): Store fd in fhandler_socket. | |
2128 | ||
1f64102f CV |
2129 | 2002-02-07 Corinna Vinschen <corinna@vinschen.de> |
2130 | ||
2131 | * net.cc (cygwin_getsockname): Fix handling of NULL sun_path. | |
2132 | ||
562d9745 CV |
2133 | 2002-01-29 Corinna Vinschen <corinna@vinschen.de> |
2134 | ||
2135 | * net.cc (getdomainname): Fix registry key for 9x systems, too. | |
2136 | ||
94ee02fa CV |
2137 | 2002-01-29 Corinna Vinschen <corinna@vinschen.de> |
2138 | ||
2139 | * net.cc (getdomainname): Fix registry key for NT systems. | |
2140 | ||
494a66d9 CF |
2141 | 2002-01-28 Christopher Faylor <cgf@redhat.com> |
2142 | ||
2143 | * external.cc (cygwin_internal): Initialize various internal settings | |
2144 | if required to allow use of some things from user loaded DLL. | |
2145 | (CW_STRACE_ON): Add new feature. | |
2146 | (CW_CYGWIN_PID_TO_WINPID): Ditto. | |
2147 | * pinfo.cc (set_myself): Call "strace.hello" to initiate possible | |
2148 | strace session. | |
2149 | (pinfo::init): Guard against dereferencing uninitialized myself. | |
2150 | * sigproc.cc (wait_sig): Call strace.hello() when __SIGTRACE "signal" | |
2151 | received. | |
2152 | * strace.cc (strace::hello): New method. | |
2153 | * wincap.cc (wincapc::init): Avoid initializing if already initialized. | |
2154 | * wincap.h (wincapc::wincapc): New method. | |
2155 | * include/sys/cygwin.h: Add new CW_ enums. Kludge typedefs of | |
2156 | {g,u}id_t if required. | |
2157 | * strace.h (strace::hello): Declare new method. | |
2158 | ||
6616e6cf CF |
2159 | 2002-01-28 Earnie Boyd <earnie@users.sf.net> |
2160 | ||
2161 | * include/sys/strace.h (_STRACE_ON): Define. | |
2162 | (_STRACE_OFF): Ditto. | |
2163 | ||
dfb4c347 CF |
2164 | 2002-01-24 Christopher Faylor <cgf@redhat.com> |
2165 | ||
2166 | * speclib: Ensure that temporary def file is removed. | |
2167 | ||
3c07fbeb CF |
2168 | 2002-01-23 Christopher Faylor <cgf@redhat.com> |
2169 | ||
2170 | * speclib: Use rm -f to remove temp file just to quiet any potential | |
2171 | warnings. | |
2172 | ||
f6fc31e1 CV |
2173 | 2002-01-23 Corinna Vinschen <corinna@vinschen.de> |
2174 | ||
2175 | * security.cc (create_token): Use sec_user() to create | |
be6d8567 CV |
2176 | SECURITY_ATTRIBUTES structure for primary token. Use |
2177 | MAXIMUM_ALLOWED access rights instead of TOKEN_ALL_ACCESS. | |
f6fc31e1 | 2178 | |
adbd01af CV |
2179 | 2002-01-23 Corinna Vinschen <corinna@vinschen.de> |
2180 | ||
2181 | * path.cc (symlink): Fix check for already existing file. | |
2182 | ||
aed69a5b CF |
2183 | 2002-01-21 Christopher Faylor <cgf@redhat.com> |
2184 | ||
2185 | * cygmagic: Suppress error output when figuring out if sum takes an | |
2186 | option. | |
2187 | ||
f3647dd7 CF |
2188 | 2002-01-21 Christopher Faylor <cgf@redhat.com> |
2189 | ||
2190 | * cygmagic: Attempt to figure out if sum takes an option. | |
2191 | ||
51076b73 CF |
2192 | 2002-01-21 DJ Delorie <dj@redhat.com> |
2193 | ||
2194 | * Makefile.in (libpthread.a): Pass the assembler also. | |
291be307 | 2195 | (libm.a): Ditto. |
51076b73 CF |
2196 | (libc.a): Ditto. |
2197 | * speclib: Specify the assembler to dlltool. | |
2198 | ||
0ac2abea CF |
2199 | 2002-01-21 Christopher Faylor <cgf@redhat.com> |
2200 | ||
2201 | * include/cygwin/version.h: Bump DLL minor number. | |
2202 | ||
ac11ec88 CV |
2203 | 2002-01-21 Corinna Vinschen <corinna@vinschen.de> |
2204 | ||
28982aa8 | 2205 | * grp.cc (getgrgid): Don't return default gid entry when ntsec is on. |
ac11ec88 CV |
2206 | * syscalls.cc (setegid): Don't set primary group in process token. |
2207 | ||
8ef47135 CF |
2208 | 2002-01-21 Christopher Faylor <cgf@redhat.com> |
2209 | ||
2210 | * speclib: Don't use /dev/null as DLL name. Just default to what's | |
2211 | already in .def file. | |
2212 | ||
2213 | 2002-01-21 Christopher Faylor <cgf@redhat.com> | |
2214 | ||
2215 | * exceptions.cc (sig_handle): Remove last vestiges of SA_NOCLDSTOP code | |
2216 | which caused SIGCHLD to be ignored. | |
2217 | ||
07cc1f1f CF |
2218 | 2002-01-20 Christopher Faylor <cgf@redhat.com> |
2219 | ||
2220 | * include/cygwin/version.h: Bump DLL minor number. | |
2221 | ||
385437d4 CF |
2222 | 2002-01-20 Christopher Faylor <cgf@redhat.com> |
2223 | ||
2224 | * syscalls.cc (regfree): Make dll_export. | |
2225 | ||
d7c16d8d CF |
2226 | 2002-01-20 Christopher Faylor <cgf@redhat.com> |
2227 | ||
2228 | * exceptions.cc (ctrl_c_handler): Convert windows pid to cygwin pid | |
2229 | when detecting if we should actually handle CTRL-C. | |
2230 | ||
216109a8 CF |
2231 | 2002-01-19 Christopher Faylor <cgf@redhat.com> |
2232 | ||
2233 | * Makefile.in (new-cygwin1.dll): Revert previous change. libsupc++.a | |
2234 | is only available in libstdc++-v3. | |
2235 | ||
9e73b339 CF |
2236 | 2002-01-19 Christopher Faylor <cgf@redhat.com> |
2237 | ||
2238 | * exceptions.cc (sig_handle_tty_stop): Don't send SIGCHLD if parent | |
2239 | doesn't want it. | |
2240 | (sig_handle): Don't check for SA_NOCLDSTOP here. We don't have enough | |
2241 | information. | |
2242 | ||
5946622e CF |
2243 | 2002-01-19 Christopher Faylor <cgf@redhat.com> |
2244 | ||
2245 | * include/cygwin/version.h: Bump DLL minor number. | |
2246 | ||
994fe87b CF |
2247 | 2002-01-19 Christopher Faylor <cgf@redhat.com> |
2248 | ||
2249 | * Makefile.in (new-cygwin1.dll): Just use -lsupc++ for link. | |
2250 | * sigproc.cc (proc_exists): Change existence criteria. | |
2251 | * sync.h (new_muto): Add volatile to definition to avoid gcc | |
2252 | optimization problems. | |
2253 | ||
df3af773 CV |
2254 | 2002-01-19 Corinna Vinschen <corinna@vinschen.de> |
2255 | ||
2256 | * include/cygwin/version.h: Bump API minor version to 51. | |
2257 | ||
7d6be0d6 CV |
2258 | 2002-01-19 Mark Bradshaw <bradshaw@staff.crosswalk.com> |
2259 | ||
291be307 CF |
2260 | * cygwin.din: Add recvmsg and sendmsg. |
2261 | * net.cc: Add cygwin_recvmsg and cygwin_sendmsg. | |
2262 | * /usr/include/sys/socket.h: Add recvmsg and sendmsg. | |
7d6be0d6 | 2263 | |
2d3dab2e CV |
2264 | 2002-01-19 Corinna Vinschen <corinna@vinschen.de> |
2265 | ||
2266 | * security.cc (create_token): Close processes token handle as soon | |
2267 | as it's not used anymore. | |
2268 | ||
104c3be6 CV |
2269 | 2002-01-17 Corinna Vinschen <corinna@vinschen.de> |
2270 | ||
2271 | * Makefile.in: Add fnmatch.o to DLL_OFILES. | |
2272 | * cygwin.din: Add fnmatch export symbol. | |
2273 | * fnmatch.c: New file. | |
2274 | * include/fnmatch.h: Ditto. | |
2275 | * include/cygwin/version.h: Bump API minor version to 50. | |
2276 | ||
9a7e1562 CV |
2277 | 2002-01-15 Corinna Vinschen <corinna@vinschen.de> |
2278 | ||
2279 | * path.cc (fchdir): Call chdir with full windows path. | |
2280 | ||
7eddac1b CV |
2281 | 2002-01-14 Corinna Vinschen <corinna@vinschen.de> |
2282 | ||
2283 | * dir.cc: Use INVALID_FILE_ATTRIBUTES instead of "(DWORD) -1" | |
2284 | for file attributes throughout. | |
2285 | * fhandler.cc: Ditto. | |
2286 | * fhandler_disk_file.cc: Ditto. | |
2287 | * path.cc: Ditto. | |
2288 | * path.h: Ditto. | |
2289 | * syscalls.cc: Ditto. | |
2290 | * times.cc (utimes): Use path_conv::isdir() instead of explicit | |
2291 | GetFileAttributes() call. | |
2292 | ||
5daa0835 CF |
2293 | 2002-01-13 Christopher Faylor <cgf@redhat.com> |
2294 | ||
2295 | * dcrt0.cc (multiple_cygwin_problem): Clarify logic and make | |
2296 | CYGWIN_MISMATCH_OK more powerful. | |
2297 | ||
06486d9e CF |
2298 | 2002-01-10 Christopher Faylor <cgf@redhat.com> |
2299 | ||
2300 | * exceptions.cc (sig_handle): Accept a second argument indicating | |
2301 | whether the signal came from this process or not. | |
2302 | * sigproc.h: Reflect sig_handle arg change. | |
2303 | * signal.cc (kill_pgrp): Add sigframe info. | |
2304 | (abort): New function. Eliminates newlib function of same name. | |
2305 | * sigproc.cc (wait_sig): Pass "signal from this process" value as arg | |
2306 | 2. | |
2307 | ||
bb5225c2 CV |
2308 | 2002-01-10 Corinna Vinschen <corinna@vinschen.de> |
2309 | ||
2310 | * syscalls.cc (pathconf): Guard _PC_PATH_MAX branch against invalid | |
2311 | file parameter. | |
2312 | ||
c0a8e8d0 | 2313 | 2002-01-09 Christopher Faylor <cgf@redhat.com> |
291be307 | 2314 | Robert Collins <rbtcollins@hotmail.com> |
c0a8e8d0 CF |
2315 | |
2316 | * exceptions.cc (early_stuff_init): Rename from misnamed | |
2317 | set_console_handler. | |
2318 | (ctrl_c_handler): Attempt to work around potential signal duplication | |
2319 | during process startup. | |
2320 | (sig_handle): Ignore SIGINT when we're just an "exec stub". | |
2321 | * spawn.cc (spawn_guts): Store pid of spawned process in global for use | |
2322 | by ctrl_c_handler. | |
2323 | * dcrt0.cc (dll_crt0_1): Call renamed initialization function. | |
2324 | * winsup.h: Reflect function name change. | |
2325 | ||
fe37dd79 CV |
2326 | 2002-01-08 Corinna Vinschen <corinna@vinschen.de> |
2327 | ||
2328 | * net.cc (cygwin_accept): Set sun_path for newly connected socket. | |
2329 | ||
cbf7a9eb CF |
2330 | 2002-01-07 Ralf Habacker <Ralf.Habacker@freenet.de> |
2331 | ||
2332 | * Makefile.in: Add uninstall target. | |
2333 | ||
a2e12d0c CF |
2334 | 2002-01-07 Christopher Faylor <cgf@redhat.com> |
2335 | ||
2336 | * sigproc.cc (getsem): Clean up debugging output. | |
2337 | ||
4a08cbfe CF |
2338 | 2002-01-07 Christopher Faylor <cgf@redhat.com> |
2339 | ||
2340 | * sigproc.cc (getsem): Set errno when unable to create own semaphore. | |
2341 | Reorganize to make clearer that error should only come from initial | |
2342 | creation of process semaphore. | |
2343 | ||
10dedaaa CF |
2344 | 2002-01-06 Christopher Faylor <cgf@redhat.com> |
2345 | ||
2346 | * dtable.cc (dtable::init_std_file_from_handle): Add some defensive | |
2347 | code to invalid handle case. | |
2348 | ||
d6154fb7 CV |
2349 | 2002-01-06 Corinna Vinschen <corinna@vinschen.de> |
2350 | ||
2351 | * ioctl.cc (ioctl): Make third argument optional. | |
2352 | * include/sys/ioctl.h: Ditto in declaration. | |
2353 | * dtable.cc (dtable::init_std_file_from_handle): Revert previous | |
2354 | bogus patch. | |
2355 | * window.cc (WndProc): Raise SIGURG instead of SIGIO in case of FD_OOB | |
2356 | message. | |
2357 | ||
9125cbd7 | 2358 | 2002-01-05 Christopher Faylor <cgf@redhat.com> |
fcb76c5d | 2359 | |
9125cbd7 CF |
2360 | * dir.cc (opendir): Guarantee release of alloced fhandler structure on |
2361 | error. | |
fcb76c5d | 2362 | |
9125cbd7 CF |
2363 | 2002-01-05 Corinna Vinschen <corinna@vinschen.de> |
2364 | ||
2365 | * exceptions.cc (sig_handle): Set default action for SIGURG to SIG_IGN. | |
2366 | ||
2367 | 2002-01-05 Corinna Vinschen <corinna@vinschen.de> | |
2edba236 CV |
2368 | |
2369 | * dtable.cc (dtable::init_std_file_from_handle): Don't treat NULL | |
2370 | handle as errorneous. | |
2371 | ||
acf05df7 CF |
2372 | 2002-01-04 Christopher Faylor <cgf@redhat.com> |
2373 | ||
2374 | * cygmagic: Change logic for equality test. | |
2375 | ||
7acba971 CF |
2376 | 2002-01-04 Christopher Faylor <cgf@redhat.com> |
2377 | ||
2378 | * dir.cc (opendir): Don't attempt to call sub-opendir if ENOENT. | |
2379 | ||
9125cbd7 | 2380 | 2002-01-04 Corinna Vinschen <corinna@vinschen.de> |
dc63cea5 CV |
2381 | |
2382 | * net.cc: Replace usage of AF_UNIX by Posix compliant AF_LOCAL | |
2383 | throughout. | |
2384 | (socketpair): Explicitly allow SOCK_STREAM and SOCK_DGRAM socket types | |
2385 | in families AF_UNIX and AF_LOCAL. Explicitly allow PF_UNSPEC, PF_LOCAL | |
2386 | and PF_INET protocols. Return error otherwise. Implement datagram | |
2387 | socketpairs. | |
2388 | ||
3b789217 CF |
2389 | 2002-01-01 Christopher Faylor <cgf@redhat.com> |
2390 | ||
291be307 | 2391 | * speclib: Remove temp files automatically. |
3b789217 | 2392 | |
2fe27909 | 2393 | 2002-01-01 Corinna Vinschen <corinna@vinschen.de> |
2fe27909 CV |
2394 | * fhandler.h (fhandler_socket::sun_path): New private member. |
2395 | (fhandler_socket::set_sun_path): New method. | |
2396 | (fhandler_socket::get_sun_path): Ditto. | |
2397 | * fhandler_socket.cc (fhandler_socket::fhandler_socket): Initialize | |
2398 | sun_path to NULL. | |
2399 | (fhandler_socket::~fhandler_socket): Free sun_path if needed. | |
2400 | (fhandler_socket::set_sun_path): New method. | |
2401 | * net.cc (cygwin_bind): Set sun_path to path of local socket file. | |
2402 | (cygwin_getsockname): Add code to return correct sockaddr for unix | |
2403 | domain sockets. |