diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2017-01-31 12:52:50 +0000 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2017-01-31 12:52:50 +0000 |
commit | 9b9a5a292d656f14c927a36bf77af4a4cf1ecb3a (patch) | |
tree | 11c1c9ad419ed1dc8bb7d3b67fe01c4befff1c1c /options.c | |
parent | c54a5d9fb3d282354e831b75fe0ad75035cb08b9 (diff) | |
parent | d8da761d54ed0d2b449e412511496e67ce8d33ac (diff) | |
download | rtmux-9b9a5a292d656f14c927a36bf77af4a4cf1ecb3a.tar.gz rtmux-9b9a5a292d656f14c927a36bf77af4a4cf1ecb3a.tar.bz2 rtmux-9b9a5a292d656f14c927a36bf77af4a4cf1ecb3a.zip |
Merge branch 'master' of github.com:tmux/tmux
Diffstat (limited to 'options.c')
-rw-r--r-- | options.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -325,7 +325,7 @@ options_isstring(struct options_entry *o) } const char * -options_tostring(struct options_entry *o, int idx) +options_tostring(struct options_entry *o, int idx, int numeric) { static char s[1024]; const char *tmp; @@ -355,7 +355,10 @@ options_tostring(struct options_entry *o, int idx) tmp = attributes_tostring(o->number); break; case OPTIONS_TABLE_FLAG: - tmp = (o->number ? "on" : "off"); + if (numeric) + xsnprintf(s, sizeof s, "%lld", o->number); + else + tmp = (o->number ? "on" : "off"); break; case OPTIONS_TABLE_CHOICE: tmp = o->tableentry->choices[o->number]; |