Date | Commit message (Collapse) |
|
Otherwise modify the response array in place since
most frameworks give you a modifiable array for you
to play with anyways.
|
|
No point in having extra code to do case-insensitive lookups,
especially since the HeaderHash implementation is already in
wide use and will only get faster as time goes by.
|
|
Avoid calling RARRAY_PTR all over the place and make the code
easier to read/audit as a result.
|
|
s/init_bad_response/init_bad_app_response/
The new name matches the variable it initializes more closely.
|
|
This allows overriding the default of "\n". Behavior remains
similar to IO#puts, the :ORS (output record separator) is
appended iff the format doesn't already end with that string.
|
|
Userspace buffering defaults are dangerous as the Ruby default
IO objects do not do line-aware buffering. This makes the
README examples with File.open much safer to use out-of-the-box
for users of the pure-Ruby version. For users on the MRI C
extension logging to regular files, this should not have any
effect as we've optimized those to do unbuffered write(2)
syscalls anyways.
|
|
Back in HTTP/0.9 days (before it was called HTTP/0.9),
"GET /uri/goes/here\r\n" was a valid HTTP request.
See rfc 1945, section 4.1 for details on this ancient
"Simple-Request" scheme used by HTTP/0.9 clients.
|
|
We're not Rack::Lint, but we still need to take steps to
avoid segfaulting if we host non-Rack::Lint-compliant
applications.
This also updates the pure variant to fail on bad applications,
too.
|
|
Remove trailing "," for enum
|
|
Add a little more tolerance for bad applications that may not
give us string objects. This should only have a minor
performance penalty for proper applications but at least ensures
we don't segfault on misbehaving apps.
|
|
rb_gc_mark_locations doesn't seem in common use for structs and
there was a fencepost error so the response element didn't seem
to be marked at times.
This should fix random errors I've been seeing on big/longer
response bodies.
|
|
Some misbehaved apps can do this to us, and we don't want
the C extension to segfault when this happens.
|
|
This was documented in the README but never implemented. Some
popular web servers set REQUEST_URI even though it's not
required by Rack, so allow this variable to be used if possible.
As a side effect, it is also less likely to be modified by
certain handlers (*cough*Rails::Rack::Static*cough*).
|
|
|