-/* $OpenBSD: cmd-capture-pane.c,v 1.33 2015/10/07 09:52:58 nicm Exp $ */
+/* $OpenBSD: cmd-capture-pane.c,v 1.34 2015/10/16 07:43:29 nicm Exp $ */
/*
* Copyright (c) 2009 Jonathan Alvarado <radobobo@users.sourceforge.net>
return (CMD_RETURN_ERROR);
}
evbuffer_add(c->stdout_data, buf, len);
+ free(buf);
if (args_has(args, 'P') && len > 0)
evbuffer_add(c->stdout_data, "\n", 1);
server_push_stdout(c);
} else {
-
bufname = NULL;
if (args_has(args, 'b'))
bufname = args_get(args, 'b');
}
}
- free(buf);
return (CMD_RETURN_NORMAL);
}