Skip to content

Conversation

@sjnam
Copy link

@sjnam sjnam commented Sep 10, 2015

  1. removes a useless line
  2. uses ngx.var.http_content_type not ngx.req.get_headers()["content-type"]
  3. The function discard_line() can be used in the read_header() function if the discard_line() can be changed so that the discard_line() function returns the “line” for the success instead of 1.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm curious about why you would need the discarded line in the first place :)

Please note that we might eventually use a specific API provided by ngx_lua to discard a line without actually loading the line into the Lua space. This return value protocol defeats this potential optimization for the future.

@agentzh
Copy link
Member

agentzh commented Sep 10, 2015

@sjnam Thank you for making contributions. Please address the issues and concerns in my comments. Thanks!

agentzh added a commit that referenced this pull request Sep 10, 2015
…headers()["content-type"]. thanks Soojin Nam for the patch in #15.
@agentzh
Copy link
Member

agentzh commented Sep 10, 2015

@sjnam Already applied two of your three changes to git master. I don't like the 3rd change since it is subject to change in the future anyway. Thank you for your contributions!

@agentzh agentzh closed this Sep 10, 2015
@sjnam sjnam deleted the minor branch September 10, 2015 14:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants