]> git.notmuchmail.org Git - notmuch/blobdiff - util/xutil.h
emacs: Add new option notmuch-search-hide-excluded
[notmuch] / util / xutil.h
index fd77f733a5b33a35dfb32bcb3055c0c1147a5303..e27070009b6839f51653f946bdc0971653915c68 100644 (file)
@@ -13,7 +13,7 @@
  * GNU General Public License for more details.
  *
  * You should have received a copy of the GNU General Public License
  * GNU General Public License for more details.
  *
  * You should have received a copy of the GNU General Public License
- * along with this program.  If not, see http://www.gnu.org/licenses/ .
+ * along with this program.  If not, see https://www.gnu.org/licenses/ .
  *
  * Author: Carl Worth <cworth@cworth.org>
  */
  *
  * Author: Carl Worth <cworth@cworth.org>
  */
@@ -25,7 +25,9 @@
 #include <sys/types.h>
 #include <regex.h>
 
 #include <sys/types.h>
 #include <regex.h>
 
-#pragma GCC visibility push(hidden)
+#ifdef __cplusplus
+extern "C" {
+#endif
 
 /* xutil.c */
 void *
 
 /* xutil.c */
 void *
@@ -43,13 +45,16 @@ xstrdup (const char *s);
 char *
 xstrndup (const char *s, size_t n);
 
 char *
 xstrndup (const char *s, size_t n);
 
-void
+/* Returns 0 for successful compilation, 1 otherwise */
+int
 xregcomp (regex_t *preg, const char *regex, int cflags);
 
 int
 xregexec (const regex_t *preg, const char *string,
          size_t nmatch, regmatch_t pmatch[], int eflags);
 
 xregcomp (regex_t *preg, const char *regex, int cflags);
 
 int
 xregexec (const regex_t *preg, const char *string,
          size_t nmatch, regmatch_t pmatch[], int eflags);
 
-#pragma GCC visibility pop
+#ifdef __cplusplus
+}
+#endif
 
 #endif
 
 #endif