mirror of
https://github.com/tmux/tmux.git
synced 2026-09-16 02:01:58 +00:00
Compare commits
9 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e476c1230b | ||
|
|
746f275d41 | ||
|
|
e2d26c20d2 | ||
|
|
81e12f5397 | ||
|
|
8f3963635b | ||
|
|
18d5232804 | ||
|
|
c515d8cae0 | ||
|
|
8237d72900 | ||
|
|
173cc3dfc5 |
13
CHANGES
13
CHANGES
@@ -1,3 +1,16 @@
|
|||||||
|
CHANGES FROM 3.7b TO 3.7c
|
||||||
|
|
||||||
|
* Build with jemalloc on macOS to avoid what appears to be a bug in calloc
|
||||||
|
(issue 5385).
|
||||||
|
|
||||||
|
* Fix scrollbar initial state so they appear on new windows (issue 5339).
|
||||||
|
|
||||||
|
* Check time periodically in loops rather than every one (issue 5367).
|
||||||
|
|
||||||
|
* Use message-style again as default for message-format.
|
||||||
|
|
||||||
|
* Unzoom before creating floating panes to avoid a crash.
|
||||||
|
|
||||||
CHANGES FROM 3.7a TO 3.7b
|
CHANGES FROM 3.7a TO 3.7b
|
||||||
|
|
||||||
* Fix so that the end of a synchronized update again triggers a redraw.
|
* Fix so that the end of a synchronized update again triggers a redraw.
|
||||||
|
|||||||
@@ -101,7 +101,7 @@ cmd_split_window_exec(struct cmd *self, struct cmdq_item *item)
|
|||||||
flags |= SPAWN_FULLSIZE;
|
flags |= SPAWN_FULLSIZE;
|
||||||
|
|
||||||
input = args_has(args, 'I');
|
input = args_has(args, 'I');
|
||||||
if (input)
|
if (input || (count == 1 && *args_string(args, 0) == '\0'))
|
||||||
empty = 1;
|
empty = 1;
|
||||||
else
|
else
|
||||||
empty = args_has(args, 'E');
|
empty = args_has(args, 'E');
|
||||||
|
|||||||
133
configure.ac
133
configure.ac
@@ -1,6 +1,6 @@
|
|||||||
# configure.ac
|
# configure.ac
|
||||||
|
|
||||||
AC_INIT([tmux], 3.7b)
|
AC_INIT([tmux], 3.7c)
|
||||||
AC_PREREQ([2.60])
|
AC_PREREQ([2.60])
|
||||||
|
|
||||||
AC_CONFIG_AUX_DIR(etc)
|
AC_CONFIG_AUX_DIR(etc)
|
||||||
@@ -76,9 +76,7 @@ AM_CONDITIONAL(IS_OPTIMIZED, test "x$enable_optimizations" = xyes)
|
|||||||
# Is this --enable-asan?
|
# Is this --enable-asan?
|
||||||
AC_ARG_ENABLE(
|
AC_ARG_ENABLE(
|
||||||
asan,
|
asan,
|
||||||
AS_HELP_STRING(--enable-asan, enable ASAN build flags),
|
AS_HELP_STRING(--enable-asan, enable ASAN build flags)
|
||||||
,
|
|
||||||
enable_asan=no
|
|
||||||
)
|
)
|
||||||
AM_CONDITIONAL(IS_ASAN, test "x$enable_asan" = xyes)
|
AM_CONDITIONAL(IS_ASAN, test "x$enable_asan" = xyes)
|
||||||
|
|
||||||
@@ -241,6 +239,7 @@ AC_LIBOBJ(getopt_long)
|
|||||||
|
|
||||||
# Look for libevent. Try libevent_core or libevent with pkg-config first then
|
# Look for libevent. Try libevent_core or libevent with pkg-config first then
|
||||||
# look for the library.
|
# look for the library.
|
||||||
|
libevent_version=off
|
||||||
PKG_CHECK_MODULES(
|
PKG_CHECK_MODULES(
|
||||||
LIBEVENT_CORE,
|
LIBEVENT_CORE,
|
||||||
[libevent_core >= 2],
|
[libevent_core >= 2],
|
||||||
@@ -249,6 +248,8 @@ PKG_CHECK_MODULES(
|
|||||||
CPPFLAGS="$AM_CPPFLAGS $SAVED_CPPFLAGS"
|
CPPFLAGS="$AM_CPPFLAGS $SAVED_CPPFLAGS"
|
||||||
LIBS="$LIBEVENT_CORE_LIBS $LIBS"
|
LIBS="$LIBEVENT_CORE_LIBS $LIBS"
|
||||||
found_libevent=yes
|
found_libevent=yes
|
||||||
|
libevent_version=`$PKG_CONFIG --modversion libevent_core 2>/dev/null`
|
||||||
|
test "x$libevent_version" = x && libevent_version=on
|
||||||
],
|
],
|
||||||
found_libevent=no
|
found_libevent=no
|
||||||
)
|
)
|
||||||
@@ -261,6 +262,8 @@ if test x$found_libevent = xno; then
|
|||||||
CPPFLAGS="$AM_CPPFLAGS $SAVED_CPPFLAGS"
|
CPPFLAGS="$AM_CPPFLAGS $SAVED_CPPFLAGS"
|
||||||
LIBS="$LIBEVENT_LIBS $LIBS"
|
LIBS="$LIBEVENT_LIBS $LIBS"
|
||||||
found_libevent=yes
|
found_libevent=yes
|
||||||
|
libevent_version=`$PKG_CONFIG --modversion libevent 2>/dev/null`
|
||||||
|
test "x$libevent_version" = x && libevent_version=on
|
||||||
],
|
],
|
||||||
found_libevent=no
|
found_libevent=no
|
||||||
)
|
)
|
||||||
@@ -269,7 +272,8 @@ if test x$found_libevent = xno; then
|
|||||||
AC_SEARCH_LIBS(
|
AC_SEARCH_LIBS(
|
||||||
event_init,
|
event_init,
|
||||||
[event_core event event-1.4],
|
[event_core event event-1.4],
|
||||||
found_libevent=yes,
|
[found_libevent=yes
|
||||||
|
libevent_version=on],
|
||||||
found_libevent=no
|
found_libevent=no
|
||||||
)
|
)
|
||||||
fi
|
fi
|
||||||
@@ -296,6 +300,7 @@ fi
|
|||||||
|
|
||||||
# Look for ncurses or curses. Try pkg-config first then directly for the
|
# Look for ncurses or curses. Try pkg-config first then directly for the
|
||||||
# library.
|
# library.
|
||||||
|
ncurses_version=off
|
||||||
PKG_CHECK_MODULES(
|
PKG_CHECK_MODULES(
|
||||||
LIBTINFOW,
|
LIBTINFOW,
|
||||||
tinfow,
|
tinfow,
|
||||||
@@ -304,6 +309,8 @@ PKG_CHECK_MODULES(
|
|||||||
CPPFLAGS="$LIBTINFOW_CFLAGS $SAVED_CPPFLAGS"
|
CPPFLAGS="$LIBTINFOW_CFLAGS $SAVED_CPPFLAGS"
|
||||||
LIBS="$LIBTINFOW_LIBS $LIBS"
|
LIBS="$LIBTINFOW_LIBS $LIBS"
|
||||||
found_ncurses=yes
|
found_ncurses=yes
|
||||||
|
ncurses_version=`$PKG_CONFIG --modversion tinfow 2>/dev/null`
|
||||||
|
test "x$ncurses_version" = x && ncurses_version=on
|
||||||
],
|
],
|
||||||
found_ncurses=no
|
found_ncurses=no
|
||||||
)
|
)
|
||||||
@@ -316,6 +323,8 @@ if test "x$found_ncurses" = xno; then
|
|||||||
CPPFLAGS="$LIBTINFO_CFLAGS $SAVED_CPPFLAGS"
|
CPPFLAGS="$LIBTINFO_CFLAGS $SAVED_CPPFLAGS"
|
||||||
LIBS="$LIBTINFO_LIBS $LIBS"
|
LIBS="$LIBTINFO_LIBS $LIBS"
|
||||||
found_ncurses=yes
|
found_ncurses=yes
|
||||||
|
ncurses_version=`$PKG_CONFIG --modversion tinfo 2>/dev/null`
|
||||||
|
test "x$ncurses_version" = x && ncurses_version=on
|
||||||
],
|
],
|
||||||
found_ncurses=no
|
found_ncurses=no
|
||||||
)
|
)
|
||||||
@@ -329,6 +338,8 @@ if test "x$found_ncurses" = xno; then
|
|||||||
CPPFLAGS="$LIBNCURSESW_CFLAGS $SAVED_CPPFLAGS"
|
CPPFLAGS="$LIBNCURSESW_CFLAGS $SAVED_CPPFLAGS"
|
||||||
LIBS="$LIBNCURSESW_LIBS $LIBS"
|
LIBS="$LIBNCURSESW_LIBS $LIBS"
|
||||||
found_ncurses=yes
|
found_ncurses=yes
|
||||||
|
ncurses_version=`$PKG_CONFIG --modversion ncursesw 2>/dev/null`
|
||||||
|
test "x$ncurses_version" = x && ncurses_version=on
|
||||||
],
|
],
|
||||||
found_ncurses=no
|
found_ncurses=no
|
||||||
)
|
)
|
||||||
@@ -342,6 +353,8 @@ if test "x$found_ncurses" = xno; then
|
|||||||
CPPFLAGS="$LIBNCURSES_CFLAGS $SAVED_CPPFLAGS"
|
CPPFLAGS="$LIBNCURSES_CFLAGS $SAVED_CPPFLAGS"
|
||||||
LIBS="$LIBNCURSES_LIBS $LIBS"
|
LIBS="$LIBNCURSES_LIBS $LIBS"
|
||||||
found_ncurses=yes
|
found_ncurses=yes
|
||||||
|
ncurses_version=`$PKG_CONFIG --modversion ncurses 2>/dev/null`
|
||||||
|
test "x$ncurses_version" = x && ncurses_version=on
|
||||||
],
|
],
|
||||||
found_ncurses=no
|
found_ncurses=no
|
||||||
)
|
)
|
||||||
@@ -350,7 +363,8 @@ if test "x$found_ncurses" = xno; then
|
|||||||
AC_SEARCH_LIBS(
|
AC_SEARCH_LIBS(
|
||||||
setupterm,
|
setupterm,
|
||||||
[tinfow tinfo terminfo ncursesw ncurses],
|
[tinfow tinfo terminfo ncursesw ncurses],
|
||||||
found_ncurses=yes,
|
[found_ncurses=yes
|
||||||
|
ncurses_version=on],
|
||||||
found_ncurses=no
|
found_ncurses=no
|
||||||
)
|
)
|
||||||
if test "x$found_ncurses" = xyes; then
|
if test "x$found_ncurses" = xyes; then
|
||||||
@@ -380,6 +394,7 @@ else
|
|||||||
LIBS="$LIBS -lcurses"
|
LIBS="$LIBS -lcurses"
|
||||||
CPPFLAGS="$CPPFLAGS -DHAVE_CURSES_H"
|
CPPFLAGS="$CPPFLAGS -DHAVE_CURSES_H"
|
||||||
AC_DEFINE(HAVE_CURSES_H)
|
AC_DEFINE(HAVE_CURSES_H)
|
||||||
|
ncurses_version=on
|
||||||
else
|
else
|
||||||
AC_MSG_ERROR("curses not found")
|
AC_MSG_ERROR("curses not found")
|
||||||
fi
|
fi
|
||||||
@@ -390,6 +405,7 @@ AC_CHECK_FUNCS([ \
|
|||||||
])
|
])
|
||||||
|
|
||||||
# Look for utempter.
|
# Look for utempter.
|
||||||
|
utempter_version=off
|
||||||
AC_ARG_ENABLE(
|
AC_ARG_ENABLE(
|
||||||
utempter,
|
utempter,
|
||||||
AS_HELP_STRING(--enable-utempter, use utempter if it is installed)
|
AS_HELP_STRING(--enable-utempter, use utempter if it is installed)
|
||||||
@@ -406,17 +422,34 @@ if test "x$enable_utempter" = xyes; then
|
|||||||
fi
|
fi
|
||||||
if test "x$enable_utempter" = xyes; then
|
if test "x$enable_utempter" = xyes; then
|
||||||
AC_DEFINE(HAVE_UTEMPTER)
|
AC_DEFINE(HAVE_UTEMPTER)
|
||||||
|
utempter_version=on
|
||||||
else
|
else
|
||||||
AC_MSG_ERROR("utempter not found")
|
AC_MSG_ERROR("utempter not found")
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Look for utf8proc.
|
# Look for utf8proc.
|
||||||
|
utf8proc_version=off
|
||||||
AC_ARG_ENABLE(
|
AC_ARG_ENABLE(
|
||||||
utf8proc,
|
utf8proc,
|
||||||
AS_HELP_STRING(--enable-utf8proc, use utf8proc if it is installed)
|
AS_HELP_STRING(--enable-utf8proc, use utf8proc if it is installed)
|
||||||
)
|
)
|
||||||
|
try_utf8proc=no
|
||||||
|
require_utf8proc=no
|
||||||
if test "x$enable_utf8proc" = xyes; then
|
if test "x$enable_utf8proc" = xyes; then
|
||||||
|
try_utf8proc=yes
|
||||||
|
elif test "x$enable_utf8proc" = x; then
|
||||||
|
case "$host_os" in
|
||||||
|
*darwin*)
|
||||||
|
try_utf8proc=yes
|
||||||
|
require_utf8proc=yes
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
if test "x$try_utf8proc" = xyes; then
|
||||||
|
SAVED_AM_CPPFLAGS="$AM_CPPFLAGS"
|
||||||
|
SAVED_OLD_CPPFLAGS="$CPPFLAGS"
|
||||||
|
SAVED_LIBS="$LIBS"
|
||||||
PKG_CHECK_MODULES(
|
PKG_CHECK_MODULES(
|
||||||
LIBUTF8PROC,
|
LIBUTF8PROC,
|
||||||
libutf8proc,
|
libutf8proc,
|
||||||
@@ -424,7 +457,10 @@ if test "x$enable_utf8proc" = xyes; then
|
|||||||
AM_CPPFLAGS="$LIBUTF8PROC_CFLAGS $AM_CPPFLAGS"
|
AM_CPPFLAGS="$LIBUTF8PROC_CFLAGS $AM_CPPFLAGS"
|
||||||
CPPFLAGS="$LIBUTF8PROC_CFLAGS $SAVED_CPPFLAGS"
|
CPPFLAGS="$LIBUTF8PROC_CFLAGS $SAVED_CPPFLAGS"
|
||||||
LIBS="$LIBUTF8PROC_LIBS $LIBS"
|
LIBS="$LIBUTF8PROC_LIBS $LIBS"
|
||||||
]
|
utf8proc_version=`$PKG_CONFIG --modversion libutf8proc 2>/dev/null`
|
||||||
|
test "x$utf8proc_version" = x && utf8proc_version=on
|
||||||
|
],
|
||||||
|
[:]
|
||||||
)
|
)
|
||||||
AC_CHECK_HEADER(utf8proc.h, enable_utf8proc=yes, enable_utf8proc=no)
|
AC_CHECK_HEADER(utf8proc.h, enable_utf8proc=yes, enable_utf8proc=no)
|
||||||
if test "x$enable_utf8proc" = xyes; then
|
if test "x$enable_utf8proc" = xyes; then
|
||||||
@@ -437,13 +473,23 @@ if test "x$enable_utf8proc" = xyes; then
|
|||||||
fi
|
fi
|
||||||
if test "x$enable_utf8proc" = xyes; then
|
if test "x$enable_utf8proc" = xyes; then
|
||||||
AC_DEFINE(HAVE_UTF8PROC)
|
AC_DEFINE(HAVE_UTF8PROC)
|
||||||
|
test "x$utf8proc_version" = xoff && utf8proc_version=on
|
||||||
else
|
else
|
||||||
AC_MSG_ERROR("utf8proc not found")
|
AM_CPPFLAGS="$SAVED_AM_CPPFLAGS"
|
||||||
|
CPPFLAGS="$SAVED_OLD_CPPFLAGS"
|
||||||
|
LIBS="$SAVED_LIBS"
|
||||||
|
utf8proc_version=off
|
||||||
|
if test "x$require_utf8proc" = xyes; then
|
||||||
|
enable_utf8proc=
|
||||||
|
else
|
||||||
|
AC_MSG_ERROR("utf8proc not found")
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
AM_CONDITIONAL(HAVE_UTF8PROC, [test "x$enable_utf8proc" = xyes])
|
AM_CONDITIONAL(HAVE_UTF8PROC, [test "x$enable_utf8proc" = xyes])
|
||||||
|
|
||||||
# Check for systemd support.
|
# Check for systemd support.
|
||||||
|
systemd_version=off
|
||||||
AC_ARG_ENABLE(
|
AC_ARG_ENABLE(
|
||||||
systemd,
|
systemd,
|
||||||
AS_HELP_STRING(--enable-systemd, enable systemd integration)
|
AS_HELP_STRING(--enable-systemd, enable systemd integration)
|
||||||
@@ -457,6 +503,8 @@ if test x"$enable_systemd" = xyes; then
|
|||||||
CPPFLAGS="$AM_CPPFLAGS $SAVED_CPPFLAGS"
|
CPPFLAGS="$AM_CPPFLAGS $SAVED_CPPFLAGS"
|
||||||
LIBS="$SYSTEMD_LIBS $LIBS"
|
LIBS="$SYSTEMD_LIBS $LIBS"
|
||||||
found_systemd=yes
|
found_systemd=yes
|
||||||
|
systemd_version=`$PKG_CONFIG --modversion libsystemd 2>/dev/null`
|
||||||
|
test "x$systemd_version" = x && systemd_version=on
|
||||||
],
|
],
|
||||||
found_systemd=no
|
found_systemd=no
|
||||||
)
|
)
|
||||||
@@ -581,11 +629,27 @@ if test "x$found_malloc_trim" = xyes; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Build against jemalloc if requested.
|
# Build against jemalloc if requested.
|
||||||
|
jemalloc_version=off
|
||||||
AC_ARG_ENABLE(
|
AC_ARG_ENABLE(
|
||||||
jemalloc,
|
jemalloc,
|
||||||
AS_HELP_STRING(--enable-jemalloc, use jemalloc if it is installed)
|
AS_HELP_STRING(--enable-jemalloc, use jemalloc if it is installed)
|
||||||
)
|
)
|
||||||
|
try_jemalloc=no
|
||||||
|
require_jemalloc=no
|
||||||
if test "x$enable_jemalloc" = xyes; then
|
if test "x$enable_jemalloc" = xyes; then
|
||||||
|
try_jemalloc=yes
|
||||||
|
elif test "x$enable_jemalloc" = x; then
|
||||||
|
case "$host_os" in
|
||||||
|
*darwin*)
|
||||||
|
try_jemalloc=yes
|
||||||
|
require_jemalloc=yes
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
if test "x$try_jemalloc" = xyes; then
|
||||||
|
SAVED_AM_CPPFLAGS="$AM_CPPFLAGS"
|
||||||
|
SAVED_OLD_CPPFLAGS="$CPPFLAGS"
|
||||||
|
SAVED_LIBS="$LIBS"
|
||||||
PKG_CHECK_MODULES(
|
PKG_CHECK_MODULES(
|
||||||
JEMALLOC,
|
JEMALLOC,
|
||||||
jemalloc,
|
jemalloc,
|
||||||
@@ -593,9 +657,26 @@ if test "x$enable_jemalloc" = xyes; then
|
|||||||
AM_CPPFLAGS="$JEMALLOC_CFLAGS $AM_CPPFLAGS"
|
AM_CPPFLAGS="$JEMALLOC_CFLAGS $AM_CPPFLAGS"
|
||||||
CPPFLAGS="$AM_CPPFLAGS $SAVED_CPPFLAGS"
|
CPPFLAGS="$AM_CPPFLAGS $SAVED_CPPFLAGS"
|
||||||
LIBS="$LIBS $JEMALLOC_LIBS"
|
LIBS="$LIBS $JEMALLOC_LIBS"
|
||||||
|
jemalloc_version=`$PKG_CONFIG --modversion jemalloc 2>/dev/null`
|
||||||
|
test "x$jemalloc_version" = x && jemalloc_version=on
|
||||||
],
|
],
|
||||||
AC_MSG_ERROR("jemalloc not found")
|
enable_jemalloc=no
|
||||||
)
|
)
|
||||||
|
if test "x$enable_jemalloc" = xno; then
|
||||||
|
AM_CPPFLAGS="$SAVED_AM_CPPFLAGS"
|
||||||
|
CPPFLAGS="$SAVED_OLD_CPPFLAGS"
|
||||||
|
LIBS="$SAVED_LIBS"
|
||||||
|
jemalloc_version=off
|
||||||
|
if test "x$require_jemalloc" = xyes; then
|
||||||
|
enable_jemalloc=
|
||||||
|
else
|
||||||
|
AC_MSG_ERROR("jemalloc not found")
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
enable_jemalloc=yes
|
||||||
|
AC_DEFINE(HAVE_JEMALLOC)
|
||||||
|
test "x$jemalloc_version" = xoff && jemalloc_version=on
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Check for CMSG_DATA. On some platforms like HP-UX this requires UNIX 95
|
# Check for CMSG_DATA. On some platforms like HP-UX this requires UNIX 95
|
||||||
@@ -942,6 +1023,20 @@ case "$host_os" in
|
|||||||
AC_MSG_NOTICE([])
|
AC_MSG_NOTICE([])
|
||||||
AC_MSG_ERROR([must give --enable-utf8proc or --disable-utf8proc])
|
AC_MSG_ERROR([must give --enable-utf8proc or --disable-utf8proc])
|
||||||
fi
|
fi
|
||||||
|
#
|
||||||
|
# macOS calloc(3) does not appear to always zero memory correctly,
|
||||||
|
# so complain and suggest using jemalloc instead.
|
||||||
|
#
|
||||||
|
if test "x$enable_jemalloc" = x; then
|
||||||
|
AC_MSG_NOTICE([])
|
||||||
|
AC_MSG_NOTICE([ macOS calloc(3) appears not to correctly])
|
||||||
|
AC_MSG_NOTICE([ zero allocations in some circumstances;])
|
||||||
|
AC_MSG_NOTICE([ to avoid this, configuring with])
|
||||||
|
AC_MSG_NOTICE([ --enable-jemalloc is recommended. To build])
|
||||||
|
AC_MSG_NOTICE([ without anyway, use --disable-jemalloc])
|
||||||
|
AC_MSG_NOTICE([])
|
||||||
|
AC_MSG_ERROR([must give --enable-jemalloc or --disable-jemalloc])
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
*dragonfly*)
|
*dragonfly*)
|
||||||
AC_MSG_RESULT(dragonfly)
|
AC_MSG_RESULT(dragonfly)
|
||||||
@@ -1029,6 +1124,26 @@ AC_MSG_CHECKING(lock-command)
|
|||||||
AC_MSG_RESULT($DEFAULT_LOCK_CMD)
|
AC_MSG_RESULT($DEFAULT_LOCK_CMD)
|
||||||
AC_SUBST(DEFAULT_LOCK_CMD)
|
AC_SUBST(DEFAULT_LOCK_CMD)
|
||||||
|
|
||||||
|
# Print a summary.
|
||||||
|
AC_MSG_NOTICE([])
|
||||||
|
if test "x$enable_asan" = xyes; then
|
||||||
|
AC_MSG_NOTICE([ASAN: on])
|
||||||
|
else
|
||||||
|
AC_MSG_NOTICE([ASAN: off])
|
||||||
|
fi
|
||||||
|
if test "x$enable_debug" = xyes; then
|
||||||
|
AC_MSG_NOTICE([debug: on])
|
||||||
|
else
|
||||||
|
AC_MSG_NOTICE([debug: off])
|
||||||
|
fi
|
||||||
|
AC_MSG_NOTICE([jemalloc: $jemalloc_version])
|
||||||
|
AC_MSG_NOTICE([libevent: $libevent_version])
|
||||||
|
AC_MSG_NOTICE([ncurses: $ncurses_version])
|
||||||
|
AC_MSG_NOTICE([systemd: $systemd_version])
|
||||||
|
AC_MSG_NOTICE([utempter: $utempter_version])
|
||||||
|
AC_MSG_NOTICE([utf8proc: $utf8proc_version])
|
||||||
|
AC_MSG_NOTICE([])
|
||||||
|
|
||||||
# Save our CFLAGS/CPPFLAGS/LDFLAGS for the Makefile and restore the old user
|
# Save our CFLAGS/CPPFLAGS/LDFLAGS for the Makefile and restore the old user
|
||||||
# variables.
|
# variables.
|
||||||
AC_SUBST(AM_CPPFLAGS)
|
AC_SUBST(AM_CPPFLAGS)
|
||||||
|
|||||||
26
format.c
26
format.c
@@ -124,6 +124,9 @@ format_job_cmp(struct format_job *fj1, struct format_job *fj2)
|
|||||||
/* Limit on time taken (milliseconds). */
|
/* Limit on time taken (milliseconds). */
|
||||||
#define FORMAT_TIME_LIMIT 100
|
#define FORMAT_TIME_LIMIT 100
|
||||||
|
|
||||||
|
/* How often to check the time in long loops. */
|
||||||
|
#define FORMAT_TIME_LOOP_CHECK 10000
|
||||||
|
|
||||||
/* Format expand flags. */
|
/* Format expand flags. */
|
||||||
#define FORMAT_EXPAND_TIME 0x1
|
#define FORMAT_EXPAND_TIME 0x1
|
||||||
#define FORMAT_EXPAND_NOJOBS 0x2
|
#define FORMAT_EXPAND_NOJOBS 0x2
|
||||||
@@ -4193,10 +4196,14 @@ found:
|
|||||||
|
|
||||||
/* Check if format has not taken too long. */
|
/* Check if format has not taken too long. */
|
||||||
static int
|
static int
|
||||||
format_check_time(struct format_expand_state *es)
|
format_check_time(struct format_expand_state *es, u_int *check)
|
||||||
{
|
{
|
||||||
uint64_t t = get_timer();
|
uint64_t t;
|
||||||
|
|
||||||
|
if (check != NULL && ++*check % FORMAT_TIME_LOOP_CHECK != 0)
|
||||||
|
return (1);
|
||||||
|
|
||||||
|
t = get_timer();
|
||||||
if (t - es->start_time < FORMAT_TIME_LIMIT)
|
if (t - es->start_time < FORMAT_TIME_LIMIT)
|
||||||
return (1);
|
return (1);
|
||||||
t -= es->start_time;
|
t -= es->start_time;
|
||||||
@@ -4211,10 +4218,11 @@ format_unescape(struct format_expand_state *es, const char *s)
|
|||||||
{
|
{
|
||||||
char *out, *cp;
|
char *out, *cp;
|
||||||
int brackets = 0;
|
int brackets = 0;
|
||||||
|
u_int check = 0;
|
||||||
|
|
||||||
cp = out = xmalloc(strlen(s) + 1);
|
cp = out = xmalloc(strlen(s) + 1);
|
||||||
for (; *s != '\0'; s++) {
|
for (; *s != '\0'; s++) {
|
||||||
if (!format_check_time(es)){
|
if (!format_check_time(es, &check)) {
|
||||||
free(out);
|
free(out);
|
||||||
return (xstrdup(""));
|
return (xstrdup(""));
|
||||||
}
|
}
|
||||||
@@ -4240,10 +4248,11 @@ format_strip(struct format_expand_state *es, const char *s)
|
|||||||
{
|
{
|
||||||
char *out, *cp;
|
char *out, *cp;
|
||||||
int brackets = 0;
|
int brackets = 0;
|
||||||
|
u_int check = 0;
|
||||||
|
|
||||||
cp = out = xmalloc(strlen(s) + 1);
|
cp = out = xmalloc(strlen(s) + 1);
|
||||||
for (; *s != '\0'; s++) {
|
for (; *s != '\0'; s++) {
|
||||||
if (!format_check_time(es)){
|
if (!format_check_time(es, &check)) {
|
||||||
free(out);
|
free(out);
|
||||||
return (xstrdup(""));
|
return (xstrdup(""));
|
||||||
}
|
}
|
||||||
@@ -4267,9 +4276,10 @@ static const char *
|
|||||||
format_skip1(struct format_expand_state *es, const char *s, const char *end)
|
format_skip1(struct format_expand_state *es, const char *s, const char *end)
|
||||||
{
|
{
|
||||||
int brackets = 0;
|
int brackets = 0;
|
||||||
|
u_int check = 0;
|
||||||
|
|
||||||
for (; *s != '\0'; s++) {
|
for (; *s != '\0'; s++) {
|
||||||
if (es != NULL && !format_check_time(es))
|
if (es != NULL && !format_check_time(es, &check))
|
||||||
return (NULL);
|
return (NULL);
|
||||||
if (*s == '#' && s[1] == '{')
|
if (*s == '#' && s[1] == '{')
|
||||||
brackets++;
|
brackets++;
|
||||||
@@ -5059,7 +5069,7 @@ format_replace(struct format_expand_state *es, const char *key, size_t keylen,
|
|||||||
struct format_modifier *list, *cmp = NULL, *search = NULL;
|
struct format_modifier *list, *cmp = NULL, *search = NULL;
|
||||||
struct format_modifier **sub = NULL, *mexp = NULL, *fm;
|
struct format_modifier **sub = NULL, *mexp = NULL, *fm;
|
||||||
struct format_modifier *bool_op_n = NULL;
|
struct format_modifier *bool_op_n = NULL;
|
||||||
u_int i, count, nsub = 0, nrep;
|
u_int i, count, nsub = 0, nrep, check = 0;
|
||||||
struct format_expand_state next;
|
struct format_expand_state next;
|
||||||
|
|
||||||
/* Set sorting defaults. */
|
/* Set sorting defaults. */
|
||||||
@@ -5346,7 +5356,7 @@ format_replace(struct format_expand_state *es, const char *key, size_t keylen,
|
|||||||
else {
|
else {
|
||||||
value = xstrdup("");
|
value = xstrdup("");
|
||||||
for (i = 0; i < nrep; i++) {
|
for (i = 0; i < nrep; i++) {
|
||||||
if (!format_check_time(es)) {
|
if (!format_check_time(es, &check)) {
|
||||||
free(right);
|
free(right);
|
||||||
free(left);
|
free(left);
|
||||||
free(value);
|
free(value);
|
||||||
@@ -5626,7 +5636,7 @@ format_expand1(struct format_expand_state *es, const char *fmt)
|
|||||||
int ch, brackets;
|
int ch, brackets;
|
||||||
char expanded[8192];
|
char expanded[8192];
|
||||||
|
|
||||||
if (fmt == NULL || *fmt == '\0' || !format_check_time(es))
|
if (fmt == NULL || *fmt == '\0' || !format_check_time(es, NULL))
|
||||||
return (xstrdup(""));
|
return (xstrdup(""));
|
||||||
|
|
||||||
if (es->loop == FORMAT_LOOP_LIMIT) {
|
if (es->loop == FORMAT_LOOP_LIMIT) {
|
||||||
|
|||||||
1
layout.c
1
layout.c
@@ -1417,6 +1417,7 @@ layout_get_floating_cell(struct cmdq_item *item, struct args *args,
|
|||||||
w->last_new_pane_y = oy;
|
w->last_new_pane_y = oy;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
window_push_zoom(wp->window, 1, args_has(args, 'Z'));
|
||||||
lcnew = layout_floating_pane(w, sx, sy, ox, oy);
|
lcnew = layout_floating_pane(w, sx, sy, ox, oy);
|
||||||
return (lcnew);
|
return (lcnew);
|
||||||
}
|
}
|
||||||
|
|||||||
13
proc.c
13
proc.c
@@ -31,6 +31,10 @@
|
|||||||
#include <ncurses.h>
|
#include <ncurses.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_JEMALLOC
|
||||||
|
#include <jemalloc/jemalloc.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "tmux.h"
|
#include "tmux.h"
|
||||||
|
|
||||||
struct tmuxproc {
|
struct tmuxproc {
|
||||||
@@ -180,6 +184,10 @@ proc_start(const char *name)
|
|||||||
{
|
{
|
||||||
struct tmuxproc *tp;
|
struct tmuxproc *tp;
|
||||||
struct utsname u;
|
struct utsname u;
|
||||||
|
#ifdef HAVE_JEMALLOC
|
||||||
|
const char *version;
|
||||||
|
size_t size = sizeof version;
|
||||||
|
#endif
|
||||||
|
|
||||||
log_open(name);
|
log_open(name);
|
||||||
setproctitle("%s (%s)", name, socket_path);
|
setproctitle("%s (%s)", name, socket_path);
|
||||||
@@ -194,6 +202,11 @@ proc_start(const char *name)
|
|||||||
#ifdef HAVE_UTF8PROC
|
#ifdef HAVE_UTF8PROC
|
||||||
log_debug("using utf8proc %s", utf8proc_version());
|
log_debug("using utf8proc %s", utf8proc_version());
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef HAVE_JEMALLOC
|
||||||
|
if (mallctl("version", &version, &size, NULL, 0) != 0)
|
||||||
|
version = "(unknown version)";
|
||||||
|
log_debug("using jemalloc %s", version);
|
||||||
|
#endif
|
||||||
#ifdef NCURSES_VERSION
|
#ifdef NCURSES_VERSION
|
||||||
log_debug("using ncurses %s %06u", NCURSES_VERSION, NCURSES_VERSION_PATCH);
|
log_debug("using ncurses %s %06u", NCURSES_VERSION, NCURSES_VERSION_PATCH);
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -438,6 +438,7 @@ server_destroy_session(struct session *s)
|
|||||||
{
|
{
|
||||||
struct client *c;
|
struct client *c;
|
||||||
struct session *s_new = NULL, *cs_new = NULL, *use_s;
|
struct session *s_new = NULL, *cs_new = NULL, *use_s;
|
||||||
|
struct sort_criteria sort_crit = { .order = SORT_NAME };
|
||||||
int detach_on_destroy;
|
int detach_on_destroy;
|
||||||
|
|
||||||
detach_on_destroy = options_get_number(s->options, "detach-on-destroy");
|
detach_on_destroy = options_get_number(s->options, "detach-on-destroy");
|
||||||
@@ -446,9 +447,11 @@ server_destroy_session(struct session *s)
|
|||||||
else if (detach_on_destroy == 2)
|
else if (detach_on_destroy == 2)
|
||||||
s_new = server_find_session(s, server_newer_detached_session);
|
s_new = server_find_session(s, server_newer_detached_session);
|
||||||
else if (detach_on_destroy == 3)
|
else if (detach_on_destroy == 3)
|
||||||
s_new = session_previous_session(s, NULL);
|
s_new = session_previous_session(s, &sort_crit);
|
||||||
else if (detach_on_destroy == 4)
|
else if (detach_on_destroy == 4)
|
||||||
s_new = session_next_session(s, NULL);
|
s_new = session_next_session(s, &sort_crit);
|
||||||
|
if (s_new == s)
|
||||||
|
s_new = NULL;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If no suitable new session was found above, then look for any
|
* If no suitable new session was found above, then look for any
|
||||||
|
|||||||
2
spawn.c
2
spawn.c
@@ -177,7 +177,7 @@ spawn_window(struct spawn_context *sc, char **cause)
|
|||||||
/* Set the name of the new window. */
|
/* Set the name of the new window. */
|
||||||
if (~sc->flags & SPAWN_RESPAWN) {
|
if (~sc->flags & SPAWN_RESPAWN) {
|
||||||
free(w->name);
|
free(w->name);
|
||||||
if (sc->name == NULL || *sc->name == '\0')
|
if (sc->name == NULL)
|
||||||
w->name = default_window_name(w);
|
w->name = default_window_name(w);
|
||||||
else {
|
else {
|
||||||
w->name = xstrdup(sc->name);
|
w->name = xstrdup(sc->name);
|
||||||
|
|||||||
2
status.c
2
status.c
@@ -630,7 +630,7 @@ status_message_redraw(struct client *c)
|
|||||||
status_prompt_area(c, &ax, &aw);
|
status_prompt_area(c, &ax, &aw);
|
||||||
|
|
||||||
ft = format_create_defaults(NULL, c, NULL, NULL, NULL);
|
ft = format_create_defaults(NULL, c, NULL, NULL, NULL);
|
||||||
memcpy(&gc, &grid_default_cell, sizeof gc);
|
style_apply(&gc, s->options, "message-style", ft);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Set #{message} in the format tree. If styles should be ignored in
|
* Set #{message} in the format tree. If styles should be ignored in
|
||||||
|
|||||||
2
window.c
2
window.c
@@ -321,6 +321,8 @@ window_create(u_int sx, u_int sy, u_int xpixel, u_int ypixel)
|
|||||||
w->ypixel = ypixel;
|
w->ypixel = ypixel;
|
||||||
|
|
||||||
w->options = options_create(global_w_options);
|
w->options = options_create(global_w_options);
|
||||||
|
w->sb = options_get_number(w->options, "pane-scrollbars");
|
||||||
|
w->sb_pos = options_get_number(w->options, "pane-scrollbars-position");
|
||||||
|
|
||||||
w->references = 0;
|
w->references = 0;
|
||||||
TAILQ_INIT(&w->winlinks);
|
TAILQ_INIT(&w->winlinks);
|
||||||
|
|||||||
Reference in New Issue
Block a user