summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2003-08-04 08:55:44 +0000
committerJim Meyering <jim@meyering.net>2003-08-04 08:55:44 +0000
commitcf572dd1d0a358928810eda6db06476c97c14591 (patch)
tree09a48c390deb18edf02f1fc0f8f7f1097e6e79cd /src
parent58a90860fcbb37465539f7f0b9abfc3c535bc129 (diff)
downloadcoreutils-cf572dd1d0a358928810eda6db06476c97c14591.tar.xz
(main): Use unsigned int instead of int for `nsigs'
and for the indices to iterate through nsigs.
Diffstat (limited to 'src')
-rw-r--r--src/sort.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/sort.c b/src/sort.c
index d92405c69..ad9b8f2e3 100644
--- a/src/sort.c
+++ b/src/sort.c
@@ -2204,7 +2204,7 @@ main (int argc, char **argv)
char *minus = "-", **files;
char const *outfile = minus;
static int const sigs[] = { SIGHUP, SIGINT, SIGPIPE, SIGTERM };
- int nsigs = sizeof sigs / sizeof *sigs;
+ unsigned int nsigs = sizeof sigs / sizeof *sigs;
#ifdef SA_NOCLDSTOP
struct sigaction oldact, newact;
#endif
@@ -2252,7 +2252,7 @@ main (int argc, char **argv)
#ifdef SA_NOCLDSTOP
{
- int i;
+ unsigned int i;
sigemptyset (&caught_signals);
for (i = 0; i < nsigs; i++)
sigaddset (&caught_signals, sigs[i]);
@@ -2263,7 +2263,7 @@ main (int argc, char **argv)
#endif
{
- int i;
+ unsigned int i;
for (i = 0; i < nsigs; i++)
{
int sig = sigs[i];