X-Git-Url: https://ncurses.scripts.mit.edu/?a=blobdiff_plain;f=ncurses%2Ftinfo%2Flib_tputs.c;h=f834532c91936f24fcfb58ef637e73e8d9a5ae1a;hb=bd2d9c5734d2c66abe0b2ddd766695b200c154fe;hp=0e52a40151a913c3b23fad8a59539b24c1f54035;hpb=6662c1ccb49cb09d0f2cec2ec6150410a0fd0f7f;p=ncurses.git diff --git a/ncurses/tinfo/lib_tputs.c b/ncurses/tinfo/lib_tputs.c index 0e52a401..f834532c 100644 --- a/ncurses/tinfo/lib_tputs.c +++ b/ncurses/tinfo/lib_tputs.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright 2018-2021,2022 Thomas E. Dickey * + * Copyright 2018-2022,2023 Thomas E. Dickey * * Copyright 1998-2016,2017 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * @@ -52,12 +52,12 @@ #include /* ospeed */ #include -MODULE_ID("$Id: lib_tputs.c,v 1.109 2022/07/21 23:26:34 tom Exp $") +MODULE_ID("$Id: lib_tputs.c,v 1.111 2023/09/16 16:05:15 tom Exp $") NCURSES_EXPORT_VAR(char) PC = 0; /* used by termcap library */ NCURSES_EXPORT_VAR(NCURSES_OSPEED) ospeed = 0; /* used by termcap library */ -NCURSES_EXPORT_VAR(int) _nc_nulls_sent = 0; /* used by 'tack' program */ +NCURSES_EXPORT_VAR(int) _nc_nulls_sent = 0; #if NCURSES_NO_PADDING NCURSES_EXPORT(void) @@ -89,6 +89,9 @@ NCURSES_SP_NAME(delay_output) (NCURSES_SP_DCLx int ms) { T((T_CALLED("delay_output(%p,%d)"), (void *) SP_PARM, ms)); + if (ms > MAX_DELAY_MSECS) + ms = MAX_DELAY_MSECS; + if (!HasTInfoTerminal(SP_PARM)) returnCode(ERR);