summaryrefslogtreecommitdiff
path: root/lib/sig2str.h
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2013-06-02 11:52:41 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2013-06-02 11:53:07 -0700
commit8da3e21131d02b62660a17e31438261c31cdfce7 (patch)
treef71fca7f4a97af0dfca183b72671325cdc23ab68 /lib/sig2str.h
parent311a4f3c3d0f5466eaf95a88d4e361efd1c9849d (diff)
downloadgnulib-8da3e21131d02b62660a17e31438261c31cdfce7.tar.gz
sig2str: port to C++
* lib/sig2str.h (sig2str, str2sig): Declare as extern "C". Reported by Daniel J Sebald in <http://lists.gnu.org/archive/html/bug-gnulib/2013-06/msg00000.html>.
Diffstat (limited to 'lib/sig2str.h')
-rw-r--r--lib/sig2str.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/sig2str.h b/lib/sig2str.h
index d16be98c07..df6bfd39e3 100644
--- a/lib/sig2str.h
+++ b/lib/sig2str.h
@@ -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. */