diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2006-07-06 19:10:32 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2006-07-06 19:10:32 +0000 |
commit | 324eddfbaa57f72437c12e0610cf47b85a635285 (patch) | |
tree | 02572884d942dedd014d2d17a4745e76e5f59e88 | |
parent | a4e695644b2dcc9be10916c6501f02ae2a97205f (diff) | |
download | newlib-324eddfbaa57f72437c12e0610cf47b85a635285.zip newlib-324eddfbaa57f72437c12e0610cf47b85a635285.tar.gz newlib-324eddfbaa57f72437c12e0610cf47b85a635285.tar.bz2 |
* Merge HEAD into cv-branch.
-rw-r--r-- | winsup/cygwin/ChangeLog | 11 | ||||
-rw-r--r-- | winsup/cygwin/child_info.h | 2 | ||||
-rw-r--r-- | winsup/cygwin/fork.cc | 2 | ||||
-rw-r--r-- | winsup/cygwin/hookapi.cc | 18 |
4 files changed, 27 insertions, 6 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index f99f88b..45dfda9 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,14 @@ +2006-07-06 Christopher Faylor <cgf@timesys.com> + + * hookapi.cc: Add comment header + (putmem): Make static. + (get_export): Ditto. + (rvadelta): Ditto. Don't assume that a section which ends where the + import_rva begins is the import list. + + * child_info.h: Update copyright. + * fork.cc: Ditto. + 2006-07-06 Corinna Vinschen <corinna@vinschen.de> * include/cygwin/in6.h (struct in6_addr): Fix typo. diff --git a/winsup/cygwin/child_info.h b/winsup/cygwin/child_info.h index c0389e8..9f11015 100644 --- a/winsup/cygwin/child_info.h +++ b/winsup/cygwin/child_info.h @@ -1,6 +1,6 @@ /* child_info.h: shared child info for cygwin - Copyright 2000, 2001, 2002, 2003, 2004, 2005 Red Hat, Inc. + Copyright 2000, 2001, 2002, 2003, 2004, 2005, 2006 Red Hat, Inc. This file is part of Cygwin. diff --git a/winsup/cygwin/fork.cc b/winsup/cygwin/fork.cc index b60a2bc..2043629 100644 --- a/winsup/cygwin/fork.cc +++ b/winsup/cygwin/fork.cc @@ -1,6 +1,6 @@ /* fork.cc - Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2004, 2005 + Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006 Red Hat, Inc. This file is part of Cygwin. diff --git a/winsup/cygwin/hookapi.cc b/winsup/cygwin/hookapi.cc index a58814e..39ba6de 100644 --- a/winsup/cygwin/hookapi.cc +++ b/winsup/cygwin/hookapi.cc @@ -1,3 +1,13 @@ +/* hookapi.cc + + Copyright 2005, 2006 Red Hat, Inc. + +This file is part of Cygwin. + +This software is a copyrighted work licensed under the terms of the +Cygwin license. Please consult the file "CYGWIN_LICENSE" for +details. */ + #include "winsup.h" #include "cygerrno.h" #include "security.h" @@ -38,19 +48,19 @@ PEHeaderFromHModule (HMODULE hModule) return pNTHeader; } -long +static long rvadelta (PIMAGE_NT_HEADERS pnt, DWORD import_rva) { PIMAGE_SECTION_HEADER section = (PIMAGE_SECTION_HEADER) (pnt + 1); for (int i = 0; i < pnt->FileHeader.NumberOfSections; i++) if (section[i].VirtualAddress <= import_rva - && (section[i].VirtualAddress + section[i].Misc.VirtualSize) >= import_rva) + && (section[i].VirtualAddress + section[i].Misc.VirtualSize) > import_rva) // if (strncasematch ((char *) section[i].Name, ".idata", IMAGE_SIZEOF_SHORT_NAME)) return section[i].VirtualAddress - section[i].PointerToRawData; return -1; } -void * +static void * putmem (PIMAGE_THUNK_DATA pi, const void *hookfn) { DWORD ofl; @@ -108,7 +118,7 @@ RedirectIAT (function_hook& fh, PIMAGE_IMPORT_DESCRIPTOR pImportDesc, return true; } -void +static void get_export (function_hook& fh) { PIMAGE_DOS_HEADER pdh = (PIMAGE_DOS_HEADER) cygwin_hmodule; |