mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-06-27 23:08:31 +00:00
Make redbean compress w/o explicit content-type (#671)
This commit is contained in:
parent
da8f5009fd
commit
d7b88734cd
2 changed files with 21 additions and 19 deletions
|
@ -1636,7 +1636,7 @@ FUNCTIONS
|
||||||
Sleeps the specified number of seconds (can be fractional). The
|
Sleeps the specified number of seconds (can be fractional). The
|
||||||
smallest interval is a microsecond.
|
smallest interval is a microsecond.
|
||||||
|
|
||||||
Route([host:str,[path:str]])
|
Route([host:str[, path:str]])
|
||||||
Instructs redbean to follow the normal HTTP serving path. This
|
Instructs redbean to follow the normal HTTP serving path. This
|
||||||
function is useful when writing an OnHttpRequest handler, since
|
function is useful when writing an OnHttpRequest handler, since
|
||||||
that overrides the serving path entirely. So if the handler
|
that overrides the serving path entirely. So if the handler
|
||||||
|
@ -1647,7 +1647,7 @@ FUNCTIONS
|
||||||
generate a 404 Not Found response if redbean couldn't find an
|
generate a 404 Not Found response if redbean couldn't find an
|
||||||
appropriate endpoint.
|
appropriate endpoint.
|
||||||
|
|
||||||
RouteHost([host:str,[path:str]]) → bool
|
RouteHost([host:str[, path:str]]) → bool
|
||||||
This is the same as Route, except it only implements the subset of
|
This is the same as Route, except it only implements the subset of
|
||||||
request routing needed for serving virtual-hosted assets, where
|
request routing needed for serving virtual-hosted assets, where
|
||||||
redbean tries to prefix the path with the hostname when looking up
|
redbean tries to prefix the path with the hostname when looking up
|
||||||
|
@ -2524,7 +2524,7 @@ ARGON2 MODULE
|
||||||
uses Argon2 can just as easily become a denial of service vector. For
|
uses Argon2 can just as easily become a denial of service vector. For
|
||||||
example, you may want to consider throttling your login endpoint.
|
example, you may want to consider throttling your login endpoint.
|
||||||
|
|
||||||
argon2.hash_encoded(pass:str, salt:int[, config:table])
|
argon2.hash_encoded(pass:str, salt:str[, config:table])
|
||||||
├─→ ascii:str
|
├─→ ascii:str
|
||||||
└─→ nil, error:str
|
└─→ nil, error:str
|
||||||
|
|
||||||
|
|
|
@ -6180,7 +6180,9 @@ static char *SetStatus(unsigned code, const char *reason) {
|
||||||
}
|
}
|
||||||
cpm.statuscode = code;
|
cpm.statuscode = code;
|
||||||
cpm.hascontenttype = false;
|
cpm.hascontenttype = false;
|
||||||
cpm.istext = false; // reset, as the headers are reset
|
// reset, as the headers are reset
|
||||||
|
// istext is -1 by default to interpret as true when not set
|
||||||
|
cpm.istext = -1;
|
||||||
cpm.gotxcontenttypeoptions = 0;
|
cpm.gotxcontenttypeoptions = 0;
|
||||||
cpm.gotcachecontrol = 0;
|
cpm.gotcachecontrol = 0;
|
||||||
cpm.referrerpolicy = 0;
|
cpm.referrerpolicy = 0;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue