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:
Diffstat (limited to 'winsup/utils/kill.cc')
-rw-r--r--winsup/utils/kill.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/winsup/utils/kill.cc b/winsup/utils/kill.cc
index 486d273f9..edabff321 100644
--- a/winsup/utils/kill.cc
+++ b/winsup/utils/kill.cc
@@ -176,8 +176,8 @@ forcekill (int pid, int sig, int wait)
if (!wait || WaitForSingleObject (h, 200) != WAIT_OBJECT_0)
if (sig && !TerminateProcess (h, sig << 8)
&& WaitForSingleObject (h, 200) != WAIT_OBJECT_0)
- fprintf (stderr, "%s: couldn't kill pid %u, %lu\n",
- prog_name, (unsigned) dwpid, GetLastError ());
+ fprintf (stderr, "%s: couldn't kill pid %u, %u\n",
+ prog_name, (unsigned) dwpid, (unsigned int) GetLastError ());
CloseHandle (h);
}
@@ -260,13 +260,13 @@ out:
if (!pid)
pid = strtoll (*argv, &p, 10);
if (*p != '\0'
- || (!force && (pid < LONG_MIN || pid > LONG_MAX))
- || (force && (pid <= 0 || pid > ULONG_MAX)))
+ || (!force && (pid < INT_MIN || pid > INT_MAX))
+ || (force && (pid <= 0 || pid > UINT_MAX)))
{
fprintf (stderr, "%s: illegal pid: %s\n", prog_name, *argv);
ret = 1;
}
- else if (pid <= LONG_MAX && kill ((pid_t) pid, sig) == 0)
+ else if (pid <= INT_MAX && kill ((pid_t) pid, sig) == 0)
{
if (force)
forcekill ((pid_t) pid, sig, 1);