changeset 10842:4a02c5d90eaf

sys_time: Add extern "C" block for C++.
author Simon Josefsson <simon@josefsson.org>
date Fri, 28 Nov 2008 15:33:48 +0100
parents 40210550f085
children 36479bd141ee
files ChangeLog lib/sys_time.in.h
diffstat 2 files changed, 14 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Thu Nov 27 15:53:05 2008 -0800
+++ b/ChangeLog	Fri Nov 28 15:33:48 2008 +0100
@@ -1,3 +1,9 @@
+2008-11-28  Simon Josefsson  <simon@josefsson.org>
+
+	* lib/sys_time.in.h: Add extern "C" block for C++.  Suggested by
+	Brian Dessent <brian@dessent.net>.  Reported by Sam Steingold
+	<sds@gnu.org>.
+
 2008-11-20  Bruno Haible  <bruno@clisp.org>
 
 	Attempt to work around an AIX 5.3, 6.1 compiler bug with include_next.
--- a/lib/sys_time.in.h	Thu Nov 27 15:53:05 2008 -0800
+++ b/lib/sys_time.in.h	Fri Nov 28 15:33:48 2008 +0100
@@ -39,6 +39,10 @@
 #  include <time.h>
 # endif
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 # if ! @HAVE_STRUCT_TIMEVAL@
 struct timeval
 {
@@ -53,4 +57,8 @@
 int gettimeofday (struct timeval *restrict, void *restrict);
 # endif
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* _GL_SYS_TIME_H */