Make improvements

- Expand redbean UNIX module
- Expand redbean documentation
- Ensure Lua copyright is embedded in binary
- Increase the PATH_MAX limit especially on NT
- Use column major sorting for linenoise completions
- Fix some suboptimalities in redbean's new UNIX API
- Figured out right flags for Multics newline in raw mode
This commit is contained in:
Justine Tunney 2022-04-24 09:59:22 -07:00
parent cf3174dc74
commit 2046c0d2ae
305 changed files with 6602 additions and 4221 deletions

View file

@ -34,7 +34,7 @@ ssize_t HasControlCodes(const char *p, size_t n, int f) {
char t[256];
wint_t x, a, b;
size_t i, j, m, g;
memset(t, 0, sizeof(t));
bzero(t, sizeof(t));
if (f & kControlC0) memset(t + 0x00, 1, 0x20 - 0x00), t[0x7F] = 1;
if (f & kControlC1) memset(t + 0x80, 1, 0xA0 - 0x80);
t['\t'] = t['\r'] = t['\n'] = t['\v'] = !!(f & kControlWs);