Update of /cvsroot/tmux/tmux
In directory vz-cvs-2.sog:/tmp/cvs-serv32037
Modified Files:
cmd.c
Log Message:
Sync OpenBSD patchset 906:
Fix a memory leak if cmd_pane_session succeeds, from Tiago Cunha.
Index: cmd.c
===================================================================
RCS file: /cvsroot/tmux/tmux/cmd.c,v
retrieving revision 1.152
retrieving revision 1.153
diff -u -d -r1.152 -r1.153
--- cmd.c 6 Apr 2011 22:29:26 -0000 1.152
+++ cmd.c 18 May 2011 20:30:36 -0000 1.153
@@ -713,20 +713,20 @@
/* A NULL argument means the current session. */
if (arg == NULL)
return (cmd_current_session(ctx, prefer_unattached));
- tmparg = xstrdup(arg);
/* Lookup as pane id. */
if ((wp = cmd_lookup_paneid(arg)) != NULL)
return (cmd_pane_session(ctx, wp, NULL));
/* Trim a single trailing colon if any. */
+ tmparg = xstrdup(arg);
arglen = strlen(tmparg);
if (arglen != 0 && tmparg[arglen - 1] == ':')
tmparg[arglen - 1] = '\0';
/* An empty session name is the current session. */
if (*tmparg == '\0') {
- xfree (tmparg);
+ xfree(tmparg);
return (cmd_current_session(ctx, prefer_unattached));
}
------------------------------------------------------------------------------
What Every C/C++ and Fortran developer Should Know!
Read this article and learn how Intel has extended the reach of its
next-generation tools to help Windows* and Linux* C/C++ and Fortran
developers boost performance applications - including clusters.
http://p.sf.net/sfu/intel-dev2devmay
_______________________________________________
tmux-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tmux-cvs