emacs-devel
[Top][All Lists]
Advanced

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

Re: master ed84f24a21: Make `signal-process' allow completing over signa


From: Po Lu
Subject: Re: master ed84f24a21: Make `signal-process' allow completing over signal names
Date: Mon, 27 Jun 2022 09:20:26 +0800
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.91 (gnu/linux)

Lars Ingebrigtsen <larsi@gnus.org> writes:

> +DEFUN ("signal-names", Fsignal_names, Ssignal_names, 0, 0, 0,
> +       doc: /* Return a list of known signal names on this system.  */)
> +  (void)
> +{
> +  char name[SIG2STR_MAX];
> +  Lisp_Object names = Qnil;
> +  for (int i = 0; i < 255; ++i)
> +    {
> +      if (!sig2str (i, name))
> +     {
> +       names = Fcons (build_string (name), names);
> +     }
> +    }
> +  return names;
> +}
> +

Shouldn't the "255" be NSIG instead? And what about systems where POSIX
signal handling doesn't really apply, such as MS Windows and MS-DOS?

Thanks.


reply via email to

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