Update of /cvsroot/tmux/tmux
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv30360
Modified Files:
cmd.c
Log Message:
Sync OpenBSD patchset 774:
Fall back on normal session choice method if $TMUX exists but is invalid
rather than rejecting.
Index: cmd.c
===================================================================
RCS file: /cvsroot/tmux/tmux/cmd.c,v
retrieving revision 1.142
retrieving revision 1.143
diff -u -d -r1.142 -r1.143
--- cmd.c 17 Jul 2010 14:38:13 -0000 1.142
+++ cmd.c 24 Oct 2010 00:32:35 -0000 1.143
@@ -339,15 +339,11 @@
}
/* Use the session from the TMUX environment variable. */
- if (data != NULL && data->pid != -1) {
- if (data->pid != getpid())
- return (NULL);
- if (data->idx > ARRAY_LENGTH(&sessions))
- return (NULL);
- if ((s = ARRAY_ITEM(&sessions, data->idx)) == NULL)
- return (NULL);
+ if (data != NULL &&
+ data->pid == getpid() &&
+ data->idx <= ARRAY_LENGTH(&sessions) &&
+ (s = ARRAY_ITEM(&sessions, data->idx)) != NULL)
return (s);
- }
return (cmd_choose_session(&sessions));
}
------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
tmux-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tmux-cvs