Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #57 from fmardini/master

A struct member rename for compatibility with errno.h
  • Loading branch information...
commit f832bf3b21e9ac75b30b80e3ce5d25d6a53f06bc 2 parents 31ee648 + 2b2ba2d
@pgriess pgriess authored
Showing with 5 additions and 5 deletions.
  1. +3 −3 http_parser.c
  2. +2 −2 http_parser.h
View
6 http_parser.c
@@ -34,13 +34,13 @@
#if HTTP_PARSER_DEBUG
#define SET_ERRNO(e) \
do { \
- parser->errno = (e); \
+ parser->http_errno = (e); \
parser->error_lineno = __LINE__; \
} while (0)
#else
#define SET_ERRNO(e) \
do { \
- parser->errno = (e); \
+ parser->http_errno = (e); \
} while(0)
#endif
@@ -1760,7 +1760,7 @@ http_parser_init (http_parser *parser, enum http_parser_type t)
parser->upgrade = 0;
parser->flags = 0;
parser->method = 0;
- parser->errno = 0;
+ parser->http_errno = 0;
}
const char *
View
4 http_parser.h
@@ -189,7 +189,7 @@ enum http_errno {
/* Get an http_errno value from an http_parser */
-#define HTTP_PARSER_ERRNO(p) ((enum http_errno) (p)->errno)
+#define HTTP_PARSER_ERRNO(p) ((enum http_errno) (p)->http_errno)
/* Get the line number that generated the current error */
#if HTTP_PARSER_DEBUG
@@ -215,7 +215,7 @@ struct http_parser {
unsigned short http_minor;
unsigned short status_code; /* responses only */
unsigned char method; /* requests only */
- unsigned char errno : 7;
+ unsigned char http_errno : 7;
/* 1 = Upgrade header was present and the parser has exited because of that.
* 0 = No upgrade header present.
Please sign in to comment.
Something went wrong with that request. Please try again.