aboutsummaryrefslogtreecommitdiff
path: root/tmux.h
diff options
context:
space:
mode:
authornicm <nicm>2015-11-18 13:06:54 +0000
committernicm <nicm>2015-11-18 13:06:54 +0000
commit64571368dc19219fc1ef9b6c20034ee143cbed0d (patch)
treedf7ea5e4787df75f08ebe9a4969c5025715cee15 /tmux.h
parentca5e6bf5f2f11796bf2bdbe136ba534e46b2e86e (diff)
downloadrtmux-64571368dc19219fc1ef9b6c20034ee143cbed0d.tar.gz
rtmux-64571368dc19219fc1ef9b6c20034ee143cbed0d.tar.bz2
rtmux-64571368dc19219fc1ef9b6c20034ee143cbed0d.zip
Sync the entire xmalloc.[ch] with the other users, but with the addition
of xrealloc, xvasprintf, xvsnprintf.
Diffstat (limited to 'tmux.h')
-rw-r--r--tmux.h21
1 files changed, 4 insertions, 17 deletions
diff --git a/tmux.h b/tmux.h
index b81bbfcd..421f2369 100644
--- a/tmux.h
+++ b/tmux.h
@@ -45,6 +45,8 @@ struct session;
struct tmuxpeer;
struct tmuxproc;
+#include "xmalloc.h"
+
/* Default global configuration file. */
#define TMUX_CONF "/etc/tmux.conf"
@@ -67,10 +69,6 @@ struct tmuxproc;
#define READ_BACKOFF 512
#define READ_TIME 100
-/* Fatal errors. */
-#define fatal(msg) log_fatal("%s: %s", __func__, msg);
-#define fatalx(msg) log_fatalx("%s: %s", __func__, msg);
-
/* Definition to shut gcc up about unused arguments. */
#define unused __attribute__ ((unused))
@@ -2214,19 +2212,8 @@ char *get_proc_name(int, char *);
void log_open(const char *);
void log_close(void);
void printflike(1, 2) log_debug(const char *, ...);
-__dead void printflike(1, 2) log_fatal(const char *, ...);
-__dead void printflike(1, 2) log_fatalx(const char *, ...);
-
-/* xmalloc.c */
-char *xstrdup(const char *);
-void *xcalloc(size_t, size_t);
-void *xmalloc(size_t);
-void *xrealloc(void *, size_t);
-void *xreallocarray(void *, size_t, size_t);
-int printflike(2, 3) xasprintf(char **, const char *, ...);
-int xvasprintf(char **, const char *, va_list);
-int printflike(3, 4) xsnprintf(char *, size_t, const char *, ...);
-int xvsnprintf(char *, size_t, const char *, va_list);
+__dead void printflike(1, 2) fatal(const char *, ...);
+__dead void printflike(1, 2) fatalx(const char *, ...);
/* style.c */
int style_parse(const struct grid_cell *,