]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - ncurses/trace/trace_buf.c
ncurses 5.9 - patch 20111022
[ncurses.git] / ncurses / trace / trace_buf.c
index 5d1c9ad3899c08bd8fbc31993188abea9b9ea177..3768d098e8a76222a0ba4f59ea57b5482286d039 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2008,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 Free Software Foundation, Inc.              *
  *                                                                          *
  * Permission is hereby granted, free of charge, to any person obtaining a  *
  * copy of this software and associated documentation files (the            *
@@ -35,7 +35,9 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: trace_buf.c,v 1.15 2010/08/28 21:08:42 tom Exp $")
+MODULE_ID("$Id: trace_buf.c,v 1.18 2011/10/22 15:46:06 tom Exp $")
+
+#ifdef TRACE
 
 #define MyList _nc_globals.tracebuf_ptr
 #define MySize _nc_globals.tracebuf_used
@@ -101,7 +103,7 @@ _nc_trace_buf(int bufnum, size_t want)
 NCURSES_EXPORT(char *)
 _nc_trace_bufcat(int bufnum, const char *value)
 {
-    char *buffer = _nc_trace_alloc(bufnum, 0);
+    char *buffer = _nc_trace_alloc(bufnum, (size_t) 0);
     if (buffer != 0) {
        size_t have = strlen(buffer);
 
@@ -112,3 +114,6 @@ _nc_trace_bufcat(int bufnum, const char *value)
     }
     return buffer;
 }
+#else
+EMPTY_MODULE(_nc_empty_trace_buf)
+#endif /* TRACE */