The branch, master has been updated
via 21bca549d35b3d0b4ff1f22f66e5e108c103ac4b (commit)
via bda970b3b14d145fcaa25cf8f3f9a3cb70a864c3 (commit)
from 75ec17f0b5204a12d15282a5167918416cd05276 (commit)
- Log -----------------------------------------------------------------
commit 21bca549d35b3d0b4ff1f22f66e5e108c103ac4b
Author: Thomas <[email protected]>
Commit: Thomas <[email protected]>
layout-resize-pane-mouse: Consider visible panes only
When a pane is maximized, and text is selected, we end up checking if a pane
switch is needed. This therefore means we might end up selecting panes
which aren't visible.
---
layout.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/layout.c b/layout.c
index b74bd78..cf554c3 100644
--- a/layout.c
+++ b/layout.c
@@ -533,6 +533,9 @@ layout_resize_pane_mouse(struct client *c)
pane_border = 0;
if (m->event & MOUSE_EVENT_DRAG && m->flags & MOUSE_RESIZE_PANE) {
TAILQ_FOREACH(wp, &w->panes, entry) {
+ if (!window_pane_visible(wp))
+ continue;
+
if (wp->xoff + wp->sx == m->lx &&
wp->yoff <= 1 + m->ly &&
wp->yoff + wp->sy >= m->ly) {
commit bda970b3b14d145fcaa25cf8f3f9a3cb70a864c3
Author: Thomas <[email protected]>
Commit: Thomas <[email protected]>
Don't treat TMUX_TMPDIR as a potential file
The point of setting TMUX_TMPDIR is to then make any labels from -L go to
that directory. In the case of makesocketpath() with no TMUX_TMPDIR set,
would set both the path and the default socket to a file. The checking of
the permissions on the file worked fine in that case, but when TMUX_TMPDIR
is set, won't work on a directory.
This fixes the problem by ensuring the check on the permissions is performed
on directories only.
---
tmux.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/tmux.c b/tmux.c
index 606c574..9c81cff 100644
--- a/tmux.c
+++ b/tmux.c
@@ -184,7 +184,8 @@ makesocketpath(const char *label)
errno = ENOTDIR;
return (NULL);
}
- if (sb.st_uid != uid || (sb.st_mode & (S_IRWXG|S_IRWXO)) != 0) {
+ if (sb.st_uid != uid || (!S_ISDIR(sb.st_mode) &&
+ sb.st_mode & (S_IRWXG|S_IRWXO)) != 0) {
errno = EACCES;
return (NULL);
}
@@ -387,7 +388,8 @@ main(int argc, char **argv)
/* -L or default set. */
if (label != NULL) {
if ((path = makesocketpath(label)) == NULL) {
- fprintf(stderr, "can't create socket\n");
+ fprintf(stderr, "can't create socket: %s\n",
+ strerror(errno));
exit(1);
}
}
-----------------------------------------------------------------------
Summary of changes:
layout.c | 3 +++
tmux.c | 6 ++++--
2 files changed, 7 insertions(+), 2 deletions(-)
hooks/post-receive
--
tmux
------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60133471&iu=/4140/ostg.clktrk
_______________________________________________
tmux-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tmux-cvs