render: bump maximum window title length from 100 to 2048 (bytes)

Apparently, the max is ~8K, but lets stay on the safe side.
This commit is contained in:
Daniel Eklöf 2020-07-22 21:07:57 +02:00
parent d58f88661f
commit 3869c7299f
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
2 changed files with 6 additions and 2 deletions

View file

@ -12,6 +12,11 @@
## Unreleased ## Unreleased
### Added ### Added
### Changed
* Maximum window title length from 100 to 2048.
### Deprecated ### Deprecated
### Removed ### Removed
### Fixed ### Fixed

View file

@ -1660,8 +1660,7 @@ render_search_box(struct terminal *term)
static void static void
render_update_title(struct terminal *term) render_update_title(struct terminal *term)
{ {
/* TODO: figure out what the limit actually is */ static const size_t max_len = 2048;
static const size_t max_len = 100;
const char *title = term->window_title != NULL ? term->window_title : "foot"; const char *title = term->window_title != NULL ? term->window_title : "foot";
char *copy = NULL; char *copy = NULL;