artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
115eecf
)
Return empty string if format is empty rather than attempting to
author
nicm
<nicm@openbsd.org>
Wed, 20 May 2015 06:39:02 +0000
(06:39 +0000)
committer
nicm
<nicm@openbsd.org>
Wed, 20 May 2015 06:39:02 +0000
(06:39 +0000)
allocate zero bytes.
usr.bin/tmux/format.c
patch
|
blob
|
history
diff --git
a/usr.bin/tmux/format.c
b/usr.bin/tmux/format.c
index
8b47b36
..
9bf9a1c
100644
(file)
--- a/
usr.bin/tmux/format.c
+++ b/
usr.bin/tmux/format.c
@@
-1,4
+1,4
@@
-/* $OpenBSD: format.c,v 1.6
6 2015/05/12 15:29:29
nicm Exp $ */
+/* $OpenBSD: format.c,v 1.6
7 2015/05/20 06:39:02
nicm Exp $ */
/*
* Copyright (c) 2011 Nicholas Marriott <nicm@users.sourceforge.net>
@@
-335,7
+335,7
@@
format_expand_time(struct format_tree *ft, const char *fmt, time_t t)
size_t tmplen;
struct tm *tm;
- if (fmt == NULL)
+ if (fmt == NULL
|| *fmt == '\0'
)
return (xstrdup(""));
tm = localtime(&t);