Both of cmdclient and curclient CAN be NULL - if the command is executed from

the configuration file. In this case, attach-session can't do much, and
new-session should just assume -d.
This commit is contained in:
Nicholas Marriott
2009-07-23 12:33:48 +00:00
parent 05b511f96a
commit 96a7cf1e6a
3 changed files with 21 additions and 8 deletions

3
tmux.h
View File

@ -862,7 +862,8 @@ struct cmd_ctx {
* cmdclient is the client which sent the MSG_COMMAND to the server, if
* any. This is NULL unless the command came from the command-line.
*
* One of curclient or cmdclient is always NULL and the other not.
* cmdclient and curclient may both be NULL if the command is in the
* configuration file.
*/
struct client *curclient;
struct session *cursession;