The branch, master has been updated
       via  3d974b7267e1e9073930a065d7a0f206f3d975f6 (commit)
      from  c5ad47ee7c7595c1d0dcf2a226742fd19d548605 (commit)

- Log -----------------------------------------------------------------
commit 3d974b7267e1e9073930a065d7a0f206f3d975f6
Author: Nicholas Marriott <[email protected]>
Commit: Nicholas Marriott <[email protected]>

    Don't let display-message crash if no client, from George Nachman.
---
 cmd-display-message.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/cmd-display-message.c b/cmd-display-message.c
index 319280b..4ff3f97 100644
--- a/cmd-display-message.c
+++ b/cmd-display-message.c
@@ -90,7 +90,10 @@ cmd_display_message_exec(struct cmd *self, struct cmd_q 
*cmdq)
        msg = format_expand(ft, out);
        if (args_has(self->args, 'p'))
                cmdq_print(cmdq, "%s", msg);
-       else
+       else if (c == NULL) {
+               cmdq_error(cmdq, "no client available");
+               return (CMD_RETURN_ERROR);
+       } else
                status_message_set(c, "%s", msg);
        free(msg);
        format_free(ft);


-----------------------------------------------------------------------

Summary of changes:
 cmd-display-message.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
tmux

------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_mar
_______________________________________________
tmux-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tmux-cvs

Reply via email to