aboutsummaryrefslogtreecommitdiff
path: root/tmux.c
diff options
context:
space:
mode:
authorNicholas Marriott <nicholas.marriott@gmail.com>2008-08-08 17:35:42 +0000
committerNicholas Marriott <nicholas.marriott@gmail.com>2008-08-08 17:35:42 +0000
commit8ed403e3093c3e04128bcac51d17cb8fa9b52d1f (patch)
tree6fc71dee24ee88c6605deffe64b5ddcffbb0b7b2 /tmux.c
parentde0e1c62843398e211d2588d9fe3c95923733afb (diff)
downloadrtmux-8ed403e3093c3e04128bcac51d17cb8fa9b52d1f.tar.gz
rtmux-8ed403e3093c3e04128bcac51d17cb8fa9b52d1f.tar.bz2
rtmux-8ed403e3093c3e04128bcac51d17cb8fa9b52d1f.zip
Tidy logging and lose stdout hacks for _info.
Diffstat (limited to 'tmux.c')
-rw-r--r--tmux.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/tmux.c b/tmux.c
index 71da57c3..48726d4b 100644
--- a/tmux.c
+++ b/tmux.c
@@ -1,4 +1,4 @@
-/* $Id: tmux.c,v 1.72 2008-07-02 21:22:57 nicm Exp $ */
+/* $Id: tmux.c,v 1.73 2008-08-08 17:35:42 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -71,15 +71,13 @@ usage(void)
void
logfile(const char *name)
{
- FILE *f;
char *path;
log_close();
if (debug_level > 0) {
xasprintf(
&path, "%s-%s-%ld.log", __progname, name, (long) getpid());
- f = fopen(path, "w");
- log_open(f, LOG_DAEMON, debug_level);
+ log_open_file(debug_level, path);
xfree(path);
}
}
@@ -205,7 +203,7 @@ main(int argc, char **argv)
argc -= optind;
argv += optind;
- log_open(stderr, LOG_USER, debug_level);
+ log_open_tty(debug_level);
siginit();
options_init(&global_options, NULL);