summaryrefslogtreecommitdiff
path: root/usr.bin/tmux
diff options
context:
space:
mode:
authorNicholas Marriott <nicm@cvs.openbsd.org>2023-10-17 09:55:33 +0000
committerNicholas Marriott <nicm@cvs.openbsd.org>2023-10-17 09:55:33 +0000
commitb6bf61cfa4f078eb13de986ed5ab222b10bc29e4 (patch)
tree2bd5086e091065295d3bb154ad2e06dee52026ac /usr.bin/tmux
parent4dd5152bda3754d6c8238063f70a240feb2e0e01 (diff)
Switch to tiparm_s (added in ncurses 6.4-20230424) instead of tparm,
which allows ncurses to validate the capabilities correctly.
Diffstat (limited to 'usr.bin/tmux')
-rw-r--r--usr.bin/tmux/tty-term.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/usr.bin/tmux/tty-term.c b/usr.bin/tmux/tty-term.c
index 8e6d76a95f0..7e0dd475b6c 100644
--- a/usr.bin/tmux/tty-term.c
+++ b/usr.bin/tmux/tty-term.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: tty-term.c,v 1.100 2023/09/02 09:17:23 nicm Exp $ */
+/* $OpenBSD: tty-term.c,v 1.101 2023/10/17 09:55:32 nicm Exp $ */
/*
* Copyright (c) 2008 Nicholas Marriott <nicholas.marriott@gmail.com>
@@ -761,7 +761,7 @@ tty_term_string_i(struct tty_term *term, enum tty_code_code code, int a)
{
const char *x = tty_term_string(term, code), *s;
- s = tparm((char *)x, a);
+ s = tiparm_s(1, 0, x, a);
if (s == NULL) {
log_debug("could not expand %s", tty_term_codes[code].name);
return ("");
@@ -774,7 +774,7 @@ tty_term_string_ii(struct tty_term *term, enum tty_code_code code, int a, int b)
{
const char *x = tty_term_string(term, code), *s;
- s = tparm((char *)x, a, b);
+ s = tiparm_s(2, 0, x, a, b);
if (s == NULL) {
log_debug("could not expand %s", tty_term_codes[code].name);
return ("");
@@ -788,7 +788,7 @@ tty_term_string_iii(struct tty_term *term, enum tty_code_code code, int a,
{
const char *x = tty_term_string(term, code), *s;
- s = tparm((char *)x, a, b, c);
+ s = tiparm_s(3, 0, x, a, b, c);
if (s == NULL) {
log_debug("could not expand %s", tty_term_codes[code].name);
return ("");
@@ -801,7 +801,7 @@ tty_term_string_s(struct tty_term *term, enum tty_code_code code, const char *a)
{
const char *x = tty_term_string(term, code), *s;
- s = tparm((char *)x, (long)a);
+ s = tiparm_s(1, 1, x, a);
if (s == NULL) {
log_debug("could not expand %s", tty_term_codes[code].name);
return ("");
@@ -815,7 +815,7 @@ tty_term_string_ss(struct tty_term *term, enum tty_code_code code,
{
const char *x = tty_term_string(term, code), *s;
- s = tparm((char *)x, (long)a, (long)b);
+ s = tiparm_s(2, 3, x, a, b);
if (s == NULL) {
log_debug("could not expand %s", tty_term_codes[code].name);
return ("");