Christopher Faylor
8297bda005
* uinfo.cc (cygheap_user::ontherange): Potentially set HOME from existing
...
homepath and homedrive cygheap_user fields (not currently used yet). Set HOME
to / if no other alternative.
(cygheap_user::test_uid): Simplify.
2002-07-01 03:57:17 +00:00
Christopher Faylor
fad1c3a8e0
white space
2002-07-01 02:36:04 +00:00
Christopher Faylor
8a2ce995f1
* environ.cc (parse_options): Use setenv to potentially replace CYGWIN value on
...
export. Fixes broken behavior since November 2000 changes.
(regopt): Return indication of whether or not something has been parsed from
the registry.
(environ_init): Only attempt to export CYGWIN variable when values were set
from the registry. It is exported automatically otherwise.
2002-07-01 02:11:30 +00:00
Christopher Faylor
fdf0b5de28
* fhandler.h (fhandler_process::pid): New field.
...
(fhandler_process::fstat): Remove unneeded array. Set pid element.
(fhandler_process::open): Ditto.
(fhandler_process::fill_filebuf): Handle case where 'p' field is NULL.
2002-06-30 23:02:58 +00:00
Christopher Faylor
ccacec81db
* fhandler.h (fhandler_process::p): New field.
...
(fhandler_process:fill_filebuf): Revert to same definition as virtual in parent
class.
(fhandler_process::open): Fill out p field rather than passing as an argument.
(fhandler_process::fill_filebuf): Use p pointer rather than argument.
2002-06-30 17:05:48 +00:00
Corinna Vinschen
c6d90e842c
* security.cc (extract_nt_dom_user): Check for all buffer overflows.
...
Call LookupAccountSid after trying to get domain & user from passwd.
(get_group_sidlist): Obtain the domain and user by calling
extract_nt_dom_user instead of LookupAccountSid.
2002-06-30 13:08:59 +00:00
Christopher Faylor
839b294201
* uinfo.cc (cygheap_user::test_uid): Use standard issetuid test.
2002-06-29 23:45:07 +00:00
Christopher Faylor
efc1575ecd
* autoload.cc (NetGetDCName): Change to make this an optional load function.
...
* cygheap.h (cygheap_user::logsrv): Return NULL when operation fails.
(cygheap_user::winname): Ditto.
(cygheap_user::domain): Ditto.
* uinfo.cc (cygheap_user::env_logsrv): Save results in temp variable.
(cygheap_user::env_userprofile): Ditto.
2002-06-29 22:05:30 +00:00
Christopher Faylor
638180f51f
* environ.cc (spenv::retrieve): Detect return of env_dontadd from cygheap_user
...
methods.
(build_env): Avoid incrementing environment pointer if not actually adding to
the environment. That could result in garbage in the environment table. Be
more defensive when reallocing envblock.
2002-06-29 17:26:13 +00:00
Christopher Faylor
38bc119696
* uinfo.cc (cygheap_user::test_uid): Return NULL or further tests are sorta
...
useless.
(cygheap_user::env_domain): Recalculate if name is missing.
2002-06-29 06:50:17 +00:00
Christopher Faylor
664075a3bb
* environ.cc (spenv::from_cygheap): Still need to take setuid into
...
consideration.
2002-06-29 06:40:19 +00:00
Christopher Faylor
e97962b92a
* uinfo.cc (cygheap_user::env_logsrv): Return "almost_null" in case where no
...
domain or username is "SYSTEM".
2002-06-29 03:14:12 +00:00
Christopher Faylor
094d519311
* cygheap.h (cygheap_user): Reorg to accommodate environment caching.
...
(cygheap_user::logsrv): New method.
(cygheap_user::winname): Ditto.
(cygheap_user::domain): Ditto.
(cygheap_user::test_uid): Ditto.
* cygheap.cc (cygheap_user::set_name): Reflect name "pwinname" name change.
* environ.cc (getwinenveq): New function.
(spenv::from_cygheap): Change arguments.
(spenv::retrieve): Ditto for call. Use getwinenveq to retrieve info from
environment. Always return value from cygwin environment, if it exists.
* environ.h (getwinenveq): Declare.
* uinfo.cc (cygheap_user::ontherange): Use logsrv() rather than env_logsrv().
(cygheap_user::test_uid): Define new method.
(cygheap_user::env_logsrv): Accept environment arguments. Use test_uid to find
info.
(cygheap_user::env_domain): Ditto.
(cygheap_user::env_userprofile): Ditto.
(cygheap_user::env_homepath): Ditto.
(cygheap_user::env_homedrive): Ditto.
(cygheap_user::env_name): Ditto.
2002-06-29 02:36:08 +00:00
Thomas Fitzsimmons
2d5eb17ee3
* libm/mathfp/sf_pow.c (powf): Change k from int to float.
2002-06-28 15:32:45 +00:00
Jeff Johnston
c1a3171f2d
2002-06-27 Benjamin Kosnik <bkoz@redhat.com>
...
* libc/include/stdio.h: Untangle, add _BEGIN_STD_C and _END_STD_C.
* libc/include/time.h: Same.
* libc/include/string.h: Same.
* libc/include/stdlib.h: Same.
* libc/include/signal.h: Same.
* libc/include/setjmp.h: Same.
* libc/include/math.h: Same.
* libc/include/locale.h: Same.
* libc/include/ctype.h: Same.
* libc/include/machine/setjmp.h: Same.
* libc/include/_ansi.h (_BEGIN_STD_C): Add.
(_END_STD_C): Add.
2002-06-27 23:58:38 +00:00
Jeff Johnston
533b4e6644
2002-06-27 Jeff Johnston <jjohnstn@redhat.com>
...
* libc/include/sys/_types.h: Define _ssize_t as int if int is
32-bits, otherwise define it as long.
* libc/include/sys/types.h: Include <_ansi.h> and <sys/_types.h>
and define ssize_t as _ssize_t.
* libc/reent/readr.c: Change return type to _ssize_t.
* libc/reent/writer.c: Ditto.
* libc/sys/linux/Makefile.am: Add aio.c.
* libc/sys/linux/Makefile.in: Regenerated.
* libc/sys/linux/aio.c: New file.
* libc/sys/linux/sys/cdefs.h: Add __restrict_arr definition.
* libm/common/fdlibm.h: Undef __P before defining it.
2002-06-27 22:48:05 +00:00
Christopher Faylor
bf75aae8b3
Add missing entry.
2002-06-27 20:45:54 +00:00
Christopher Faylor
179cae11d7
* cygheap.cc (cfree_and_set): New function.
...
(cygheap_user::set_name): Use cfree_and_set to reset members.
* cygheap.h (cygheap_user): Delete static members.
(cygheap_user::puserprof): New member.
(cfree_and_set): Declare.
* dcrt0.cc (almost_null): Define.
* winsup.h (almost_null): Declare.
* syscalls.cc (cfree_and_set): Remove unused variable.
* uinfo.cc (cygheap_user::homepath_env_buf): Eliminate.
(cygheap_user::homedrive_env_buf): Ditto.
(cygheap_user::userprofile_env_buf): Ditto.
(cygheap_user::ontherange): YA change to try to preserve existing HOMEPATH and
HOMEDRIVE. Return almost_null values when variables should not actually exist.
(cygheap_user::env_logsrv): Ditto.
(cygheap_user::env_domain): Ditto.
(cygheap_user::env_userprofile): Ditto.
2002-06-27 20:44:27 +00:00
Thomas Fitzsimmons
54be629f41
* libm/mathfp/s_pow.c (pow): Fix checks on variable k. Add
...
exponent_is_even_int variable. Handle case where x is
negative, and y is an odd integer.
* libm/mathfp/sf_pow.c (powf): Likewise.
2002-06-27 20:41:49 +00:00
Thomas Fitzsimmons
c36e6dd754
* libm/mathfp/er_lgamma.c: Remove __kernel references.
...
* libm/mathfp/erf_lgamma.c: Likewise.
* libm/mathfp/s_tgamma.c: Likewise.
* libm/mathfp/sf_tgamma.c: Likewise.
2002-06-27 20:25:57 +00:00
Jeff Johnston
baf051ca35
2002-06-27 Jeff Johnston <jjohnstn@redhat.com>
...
* libc/sys/linux/Makefile.am: Add new clock routines.
* libc/sys/linux/Makefile.in: Regenerated.
* libc/sys/linux/clock_getres.c: New file.
* libc/sys/linux/clock_gettime.c: Ditto.
* libc/sys/linux/clock_settime.c: Ditto.
* libc/sys/linux/hp-timing.h: Ditto.
* libc/sys/linux/libc-internal.h: Ditto.
* libc/sys/linux/sysconf.c: Fix typo.
* libc/sys/linux/include/time.h: New file.
* libc/sys/linux/machine/hp-timing.h: New file.
* libc/sys/linux/machine/i386/Makefile.am: Add new files.
* libc/sys/linux/machine/i386/Makefile.in: Regenerated.
* libc/sys/linux/machine/i386/get_clockfreq.c: New file.
* libc/sys/linux/machine/i386/hp-timing.c: Ditto.
* libc/sys/linux/machine/i386/hp-timing.h: Ditto.
* libc/sys/linux/sys/linux_time.h: Ditto.
* libc/sys/linux/sys/time.h: Remove include of <linux/time.h> and
replace with <sys/linux_time.h>.
2002-06-27 20:09:26 +00:00
Conrad Scott
d3c260c334
Delete extraneous comment from my previous change.
2002-06-27 20:08:33 +00:00
Corinna Vinschen
eba23038af
* dcrt0.cc (dll_crt0_1): Let __progname point to the applications
...
basename. Move eliminating ".exe" suffix from argv[0] so that it
always also affects __progname.
2002-06-27 16:01:38 +00:00
Christopher Faylor
196cdd45f6
* thread.cc (pthread::create): Added trace printf to get CreateThread
...
LastError.
2002-06-27 14:19:30 +00:00
Corinna Vinschen
5b509758a0
* mmap.cc (list::match): Check using pagesize aligned size.
2002-06-27 13:01:35 +00:00
Christopher Faylor
75c6a983c6
* fhandler_disk_file.cc (fhandler_disk_file::fstat_by_name): Force
...
FindFirstFile on first file of directory when asking for x:\ .
2002-06-27 03:06:44 +00:00
Christopher Faylor
b3e2d035bb
* cygheap.cc (cygheap_user::set_name): Correct thinko in below change.
2002-06-27 02:29:57 +00:00
Christopher Faylor
c99902b9b0
* cygheap.cc (cygheap_user::set_name): Avoid clearing things when just setting
...
name to itself or during first time initialization.
* environ.cc (check_case_init): Make case insensitive.
2002-06-26 19:39:05 +00:00
Corinna Vinschen
be5007aa52
* fhandler.h (fhandler_socket::bind): Add method definition.
...
(fhandler_socket::connect): Ditto.
(fhandler_socket::listen): Ditto.
(fhandler_socket::accept): Ditto.
(fhandler_socket::getsockname): Ditto.
(fhandler_socket::getpeername): Ditto.
(fhandler_socket::recvfrom): Ditto.
(fhandler_socket::recvmsg): Ditto.
(fhandler_socket::sendto): Ditto.
(fhandler_socket::sendmsg): Ditto.
(fhandler_socket::shutdown): Ditto.
* fhandler_socket.cc (get_inet_addr): Move here from net.cc.
(fhandler_socket::bind): New method.
(fhandler_socket::connect): Ditto.
(fhandler_socket::listen): Ditto.
(fhandler_socket::accept): Ditto.
(fhandler_socket::getsockname): Ditto.
(fhandler_socket::getpeername): Ditto.
(fhandler_socket::recvfrom): Ditto.
(fhandler_socket::recvmsg): Ditto.
(fhandler_socket::sendto): Ditto.
(fhandler_socket::sendmsg): Ditto.
(fhandler_socket::shutdown): Ditto.
* net.cc: Various formatting cleanups throughout.
(get_inet_addr): Move to fhandler_socket.cc.
(cygwin_bind): Move base functionality to appropriate fhandler_socket
method.
(cygwin_connect): Ditto.
(cygwin_listen): Ditto.
(cygwin_accept): Ditto.
(cygwin_getsockname): Ditto.
(cygwin_getpeername): Ditto.
(cygwin_recvfrom): Ditto.
(cygwin_recvmsg): Ditto.
(cygwin_sendto): Ditto.
(cygwin_sendmsg): Ditto.
(cygwin_shutdown): Ditto.
2002-06-26 19:25:09 +00:00
Joern Rennecke
0431ed4e0d
ld:
...
* emulparams/shelf.sh (STACK_ADDR): Don't define.
(OTHER_SECTIONS): Define.
* emulparams/shelf_nbsd.sh ((STACK_ADDR): Don't undef.
(OTHER_SECTIONS): Undef.
newlib:
* libc/sys/sh/crt0.S: Remove vestigial .section directive.
gcc:
* config/sh/crt1.asm: remove _stack label definition
and sentinel value.
2002-06-26 15:42:34 +00:00
Corinna Vinschen
303af15742
* pwdgrp.h (pwdgrp_read::~pwdgrp_read): Avoid compiler warning.
2002-06-26 14:59:22 +00:00
Christopher Faylor
8698edb8ae
* dcrt0.cc (_dcrt0): Be more defensive when reserved block is used and it's not
...
cygwin info.
2002-06-26 05:37:29 +00:00
Christopher Faylor
f279e522b0
* autoload (noload): Avoid clobbering bx register.
...
* environ.cc (codepage_init): Use case insensitive match.
* fhandler_console.cc (cp_get_internal): Delete.
(con_to_str): Use get_cp to derive code page.
(str_to_con): Ditto.
* miscfuncs.cc (get_cp): New function.
(sys_wcstombs): New function. Converted from macro.
(sys_mbstowcs): Ditto.
* winsup.h: Reflect above changes.
2002-06-26 05:29:41 +00:00
Christopher Faylor
109e482278
* winsup.h: Minor cleanup.
...
* path.h (path_conv::[]): New operator.
* syscalls.cc (_link): Use path_conv operators rather than methods, where
appropriate. Minor white space cleanup.
* include/cygwin/version.h: Bump DLL minor number.
* dcrt0.cc (sm): Make NO_COPY.
2002-06-26 04:21:01 +00:00
Conrad Scott
b4b15309b7
* include/winbase.h (FILE_FLAG_FIRST_PIPE_INSTANCE): Add constant.
2002-06-25 21:16:46 +00:00
Danny Smith
8e8a913ff1
2002-06-26 Casper S. Hornstrup <chorns@users.sourceforge.net>
...
* include/winbase.h (WINBASEAPI): Don't define if prior
definition.
* include/winioctl.h (PARTITION_FAT32, PARTITION_FAT32_XINT13,
PARTITION_XINT13, PARTITION_XINT13_EXTENDED, PARTITION_LDM,
PARTITION_UNIX): Add defines.
(PDRIVE_LAYOUT_INFORMATION): Add typedef.
(IsRecognizedPartition): Also check for PARTITION_FAT32,
PARTITION_FAT32_XINT13 and PARTITION_XINT13.
(IsContainerPartition): Add macro.
2002-06-25 21:05:19 +00:00
Jeff Johnston
fc067ba5b8
2002-06-25 Jeff Johnston <jjohnstn@redhat.com>
...
* libc/sys/linux/Makefile.am: Consolidate additional items under
ADD_OBJS.
* libc/sys/linux/Makefile.in: Regenerated.
2002-06-25 18:17:25 +00:00
Jeff Johnston
ffddf61ea7
2002-06-25 Jeff Johnston <jjohnstn@redhat.com>
...
* libc/sys/linux/sethostname.c: New file.
* libc/sys/linux/Makefile.am: Add sethostname.c support.
* libc/sys/linux/Makefile.in: Regenerated.
2002-06-25 18:05:31 +00:00
Corinna Vinschen
6331b65843
* syscalls.cc (chown): Convert uid to 32 bit.
...
(lchown): Ditto.
(fchown): Ditto.
2002-06-25 08:06:29 +00:00
Danny Smith
e85e106d88
2002-06-25 Ken Fitlike <kenfitlike@hotmail.com>
...
* include/commctrl.h: (CBEIF_*): Add defines.
(CBEN_*): Add defines and UNICODE mappings
(WC_COMBOBOXEX[AW]): Add defines and UNICODE mappings.
(CBEMAXSTRLEN): Add define.
(COMBOBOXEXITEM[AW]): Add structures and typedefs.
(NMCOMBOBOXEX[AW]): Add structures and typedefs.
(NMCBEDRAGBEGIN[AW]): Add structure and typedefs.
(NMCBEENDEDIT[AW]): Add structure and typedefs.
2002-06-25 03:26:21 +00:00
Christopher Faylor
0914e17db5
Update from Joshua Daniel Franklin
2002-06-25 01:16:23 +00:00
DJ Delorie
0fa276e1d5
merge from gcc
2002-06-25 01:03:52 +00:00
Jeff Johnston
1e7ca7111f
Fix typo in latest change to libc/machine/sh - new file should be strlen.S.
2002-06-25 00:02:32 +00:00
Thomas Fitzsimmons
d5487d3fb7
* libc/search/db_local.h: New file.
...
* libc/include/db.h: Remove.
* libc/search/Makefile.am (LIB_SOURCES): Add db_local.h.
* libc/search/hash.c (MIN,MAX): Add macros. Change <db.h> to
"db_local.h".
* libc/search/hash_bigkey.c: Likewise.
* libc/search/hash_buf.c: Likewise.
* libc/search/hash_func.c: Likewise.
* libc/search/hash_log2.c: Likewise.
* libc/search/hash_page.c: Likewise.
2002-06-24 23:05:08 +00:00
Jeff Johnston
59c6d6c4b5
2002-06-24 Jeff Johnston <jjohnstn@redhat.com>
...
* libc/sys/linux/gethostname.c: Change name to __gethostname and
add gethostname alias.
2002-06-24 21:46:06 +00:00
Christopher Faylor
e773b7cf30
* dtable.cc (dtable::find_unused_handle): Avoid coercion.
2002-06-24 21:14:04 +00:00
Joern Rennecke
e08a611849
* libc/machine/sh/strcpy.S: New file.
...
* libc/machine/sh/Makefile.am (lib_a_SOURCES): Add rule for it.
* libc/machine/sh/Makefile.am: Regenerate.
2002-06-24 20:30:08 +00:00
Jeff Johnston
a5dadf33f9
Fix typos.
2002-06-24 20:09:40 +00:00
Christopher Faylor
4c78be52df
* dtable.cc (fhandler_base::dup2): Cleanup. Ensure that lock is turned off in
...
error condition.
2002-06-24 20:05:52 +00:00
Jeff Johnston
a70486d790
2002-06-24 Jeff Johnston <jjohnstn@redhat.com>
...
* libc/include/math.h: Remove <sys/types.h>.
(__dmath): Use __ULong instead of _uint32_t.
* libc/include/sys/reent.h: If long or int is not 32-bits,
include <sys/types.h> to get definitions for _int32_t and _uint32_t.
* libc/stdlib/mprec.h: Include <sys/types.h> to get integer defs.
* libm/common/fdlibm.h: Ditto.
2002-06-24 20:03:38 +00:00