Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Marvin Scholz
Icecast-Server
Commits
6f66e1b7
Commit
6f66e1b7
authored
Aug 16, 2002
by
Michael Smith
Browse files
bugfixes for httpp_parse_response
svn path=/trunk/httpp/; revision=3834
parent
5a60e7c0
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/httpp/httpp.c
View file @
6f66e1b7
...
...
@@ -162,15 +162,14 @@ int httpp_parse_response(http_parser_t *parser, char *http_data, unsigned long l
return
0
;
}
httpp_setvar
(
parser
,
HTTPP_VAR_ERROR_CODE
,
resp_code
);
code
=
atoi
(
resp_code
);
if
(
code
<
200
||
code
>=
300
)
{
httpp_setvar
(
parser
,
HTTPP_VAR_ERROR_MESSAGE
,
message
);
free
(
data
);
return
0
;
}
httpp_setvar
(
parser
,
HTTPP_VAR_URI
,
uri
);
httpp_setvar
(
parser
,
HTTPP_VAR_REQ_TYPE
,
"
RELAY
"
);
httpp_setvar
(
parser
,
HTTPP_VAR_REQ_TYPE
,
"
NONE
"
);
parse_headers
(
parser
,
line
,
lines
);
...
...
src/httpp/httpp.h
View file @
6f66e1b7
...
...
@@ -13,6 +13,7 @@
#define HTTPP_VAR_URI "__uri"
#define HTTPP_VAR_REQ_TYPE "__req_type"
#define HTTPP_VAR_ERROR_MESSAGE "__errormessage"
#define HTTPP_VAR_ERROR_CODE "__errorcode"
typedef
enum
httpp_request_type_tag
{
httpp_req_none
,
httpp_req_get
,
httpp_req_post
,
httpp_req_head
,
httpp_req_source
,
httpp_req_play
,
httpp_req_stats
,
httpp_req_unknown
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment