# HG changeset patch # User Paul Eggert # Date 1370199161 25200 # Node ID 90f3d53e01f556aad8376b6bfa7b763552cd31c6 # Parent 828f503029b0d7cc5b35283dc7b8542f0223da57 sig2str: port to C++ * lib/sig2str.h (sig2str, str2sig): Declare as extern "C". Reported by Daniel J Sebald in . diff -r 828f503029b0 -r 90f3d53e01f5 ChangeLog --- a/ChangeLog Thu May 30 11:27:45 2013 -0600 +++ b/ChangeLog Sun Jun 02 11:52:41 2013 -0700 @@ -1,3 +1,10 @@ +2013-06-02 Paul Eggert + + sig2str: port to C++ + * lib/sig2str.h (sig2str, str2sig): Declare as extern "C". + Reported by Daniel J Sebald in + . + 2013-05-30 Eric Blake docs: mention cygwin shortcoming in diff -r 828f503029b0 -r 90f3d53e01f5 lib/sig2str.h --- a/lib/sig2str.h Thu May 30 11:27:45 2013 -0600 +++ b/lib/sig2str.h Sun Jun 02 11:52:41 2013 -0700 @@ -27,9 +27,17 @@ /* Size of a buffer needed to hold a signal name like "HUP". */ # define SIG2STR_MAX (sizeof "SIGRTMAX" + INT_STRLEN_BOUND (int) - 1) +#ifdef __cplusplus +extern "C" { +#endif + int sig2str (int, char *); int str2sig (char const *, int *); +#ifdef __cplusplus +} +#endif + #endif /* An upper bound on signal numbers allowed by the system. */