]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Add comment.
authorBruno Haible <bruno@clisp.org>
Sat, 27 Jun 2020 20:43:16 +0000 (22:43 +0200)
committerBruno Haible <bruno@clisp.org>
Sat, 27 Jun 2020 20:43:16 +0000 (22:43 +0200)
* gettext-tools/src/plural-eval.c (sigfpe_handler): Add comment.

gettext-tools/src/plural-eval.c

index 63fac81c33182898350d928280e4782dc1d16ed9..82fbe56ef41d218c46b516405840920b145865d9 100644 (file)
@@ -1,5 +1,5 @@
 /* Expression evaluation for plural form selection.
-   Copyright (C) 2000-2003, 2005, 2019 Free Software Foundation, Inc.
+   Copyright (C) 2000-2003, 2005, 2019-2020 Free Software Foundation, Inc.
    Written by Ulrich Drepper <drepper@cygnus.com>, 2000.
 
    This program is free software: you can redistribute it and/or modify
@@ -49,6 +49,9 @@ static _GL_ASYNC_SAFE void
 sigfpe_handler (int sig, siginfo_t *sip, void *scp)
 {
   sigfpe_code = sip->si_code;
+  /* This handler is invoked on the thread that caused the SIGFPE, that is,
+     the thread that is doing plural evaluation.  Therefore it's OK to use
+     siglongjmp.  */
   siglongjmp (sigfpe_exit, 1);
 }
 
@@ -59,6 +62,9 @@ sigfpe_handler (int sig, siginfo_t *sip, void *scp)
 static _GL_ASYNC_SAFE void
 sigfpe_handler (int sig)
 {
+  /* This handler is invoked on the thread that caused the SIGFPE, that is,
+     the thread that is doing plural evaluation.  Therefore it's OK to use
+     siglongjmp.  */
   siglongjmp (sigfpe_exit, 1);
 }