Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2003-09-18 05:46:18 +0400
committerChristopher Faylor <me@cgf.cx>2003-09-18 05:46:18 +0400
commitb1e00863f3c6c84b0ae3a67db9d3b20f536ffb72 (patch)
treeeed7e7c7785aa8ba8d746de9172d48f458f22f3a /winsup/utils
parentf7f542063b1f8231286d2a275d465bd887305b50 (diff)
* parse_pe.cc (exclusion::sort_and_check): Make error message a little more
explicit and ignore (hopefully) harmless region overlap.
Diffstat (limited to 'winsup/utils')
-rw-r--r--winsup/utils/ChangeLog5
-rw-r--r--winsup/utils/kill.cc14
-rw-r--r--winsup/utils/parse_pe.cc6
3 files changed, 16 insertions, 9 deletions
diff --git a/winsup/utils/ChangeLog b/winsup/utils/ChangeLog
index 2e930846c..62399be9a 100644
--- a/winsup/utils/ChangeLog
+++ b/winsup/utils/ChangeLog
@@ -1,3 +1,8 @@
+2003-09-17 Christopher Faylor <cgf@redhat.com>
+
+ * parse_pe.cc (exclusion::sort_and_check): Make error message a little
+ more explicit and ignore (hopefully) harmless region overlap.
+
2003-09-13 Christopher Faylor <cgf@redhat.com>
* kill.c (forcekill): Wait for process to terminate even if
diff --git a/winsup/utils/kill.cc b/winsup/utils/kill.cc
index dc654a236..8067cf825 100644
--- a/winsup/utils/kill.cc
+++ b/winsup/utils/kill.cc
@@ -149,8 +149,8 @@ main (int argc, char **argv)
{
int sig = SIGTERM;
int force = 0;
- char *gotsig = NULL;
int ret = 0;
+ char *gotasig = NULL;
prog_name = strrchr (argv[0], '/');
if (prog_name == NULL)
@@ -173,8 +173,8 @@ main (int argc, char **argv)
switch (ch)
{
case 's':
- gotsig = optarg;
- sig = getsig (gotsig);
+ gotasig = optarg;
+ sig = getsig (gotasig);
break;
case 'l':
if (!optarg)
@@ -200,12 +200,12 @@ main (int argc, char **argv)
print_version ();
break;
case '?':
- if (gotsig)
+ if (gotasig)
usage ();
optreset = 1;
optind = 1 + av - argv;
- gotsig = *av + 1;
- sig = getsig (gotsig);
+ gotasig = *av + 1;
+ sig = getsig (gotasig);
break;
default:
usage ();
@@ -213,7 +213,7 @@ main (int argc, char **argv)
}
}
- test_for_unknown_sig (sig, gotsig);
+ test_for_unknown_sig (sig, gotasig);
argv += optind;
while (*argv != NULL)
diff --git a/winsup/utils/parse_pe.cc b/winsup/utils/parse_pe.cc
index 07242da87..4dc7d4f0a 100644
--- a/winsup/utils/parse_pe.cc
+++ b/winsup/utils/parse_pe.cc
@@ -1,6 +1,6 @@
/* parse_pe.cc
- Copyright 1999,2000,2001 Red Hat, Inc.
+ Copyright 1999, 2000, 2001, 2002, 2003 Red Hat, Inc.
Written by Egor Duda <deo@logos-m.ru>
@@ -47,9 +47,11 @@ exclusion::sort_and_check ()
for (process_mem_region * p = region; p < region + last - 1; p++)
{
process_mem_region *q = p + 1;
+ if (q == p + 1)
+ continue;
if (p->base + size > q->base)
{
- fprintf (stderr, "region error @ %08x", (unsigned) p->base);
+ fprintf (stderr, "region error @ (%8p + %d) > %8p\n", (unsigned) p->base, size, q->base);
return 0;
}
}