bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: What signal should timeout send when it gets a SIGTERM?


From: Pádraig Brady
Subject: Re: What signal should timeout send when it gets a SIGTERM?
Date: Tue, 16 Mar 2010 11:33:54 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.8) Gecko/20100227 Thunderbird/3.0.3

On 16/03/10 07:10, Jim Meyering wrote:
> Pádraig Brady wrote:
>> address@hidden --kill-delay
> 
> The long option name makes it sound like this
> is merely specifying the delay, when in fact it is
> enabling new behavior as well.  Did you consider say,
> "--kill-after=DELAY" ?
> 
> Whatever its name, saying what happens *without* the option
> might clarify:
> 
>     Without this option, if the selected signal proves not to be fatal,
>     @command{timeout} does not kill the @var{command}.

That's better. I'll push the attached patch today sometime.

>> +          alarm(kill_delay);
> 
> We need one of those pesky space-before paren things ;-)
> There's also one missing on a sigemptyset use.

Grr :)

There are a few of those:
for c in *.c;
  do echo "*******$c*******"
  cpp -fpreprocessed $c 2>/dev/null | grep '[a-zA-Z0-9]('
done

*******copy.c*******
      if (!(sb.st_mode & S_IWUSR) && geteuid() != 0)
*******dd.c*******
  input_offset = MAX(0, offset);
*******join.c*******
      prjoin(seq1.lines[0], seq2.lines[0]);
*******pwd.c*******
  if (stat (wd, &st1) == 0 && stat (".", &st2) == 0 && SAME_INODE(st1, st2))
*******sort.c*******
                     long_options[oi].name, quote(s));
                     long_options[oi].name, quote("2"));
             long_options[oi].name, quote(s));
  free(fps);
  free(buffer);
  free(ord);
  free(base);
  free(cur);
                memmove(&files[i + 1], &files[i + num_merged],
      memmove(&files[out], &files[in], (nfiles - in) * sizeof *files);
*******uptime.c*******
      printf(_("  \
      printf(_("\n"));

cheers,
Pádraig.

Attachment: timeout-kill-delay.diff
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]