diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2025-06-09 10:57:33 +0200 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2025-06-09 10:57:33 +0200 |
commit | 221e75b9ba1149c4a3057a32d5e8fcc07ffa5d61 (patch) | |
tree | c9d655b747ca5b1b59899d6cbb5a2674891f521a | |
parent | 728e5da4286acb554136b4dcfb6e72901db67163 (diff) |
kd: Discard more ansi sequences
The full range between @ and ~ is defined to be potential ANSI
sequences, so ignore them all.
-rw-r--r-- | i386/i386at/kd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/i386/i386at/kd.c b/i386/i386at/kd.c index 3774fe79..ea2e4ef5 100644 --- a/i386/i386at/kd.c +++ b/i386/i386at/kd.c @@ -1499,7 +1499,7 @@ kd_parserest(u_char *cp) case '\0': break; /* not enough yet */ default: - if ((*cp >= 'a' && *cp <= 'z') || (*cp >= 'A' && *cp <= 'Z')) + if (*cp >= '@' && *cp <= '~') { /* Unsupported sequence, just silently drop */ } @@ -1517,7 +1517,7 @@ kd_parserest(u_char *cp) case '\0': break; /* not enough yet */ default: - if ((*cp >= 'a' && *cp <= 'z') || (*cp >= 'A' && *cp <= 'Z')) + if (*cp >= '@' && *cp <= '~') { /* Unsupported sequence, just silently drop */ } @@ -1775,7 +1775,7 @@ kd_parserest(u_char *cp) case '\0': break; /* not enough yet */ default: - if ((*cp >= 'a' && *cp <= 'z') || (*cp >= 'A' && *cp <= 'Z')) + if (*cp >= '@' && *cp <= '~') { /* Unsupported sequence, just silently drop */ } |