Mercurial > mplayer.hg
annotate libmpdemux/http.h @ 2637:8101229be3a5
code cleanup
author | nick |
---|---|
date | Fri, 02 Nov 2001 18:24:25 +0000 |
parents | 0ecc1b4f7cf8 |
children | 80189681c02b |
rev | line source |
---|---|
902 | 1 /* |
2 * HTTP Helper | |
3 * by Bertrand Baudet <bertrand_baudet@yahoo.com> | |
4 * (C) 2001, MPlayer team. | |
5 */ | |
6 | |
870 | 7 #ifndef __HTTP_H |
8 #define __HTTP_H | |
9 | |
10 #define HTTP_FIELD_MAX 20 | |
11 | |
12 typedef struct { | |
13 char *protocol; | |
14 char *method; | |
15 char *uri; | |
16 int status_code; | |
17 char *reason_phrase; | |
18 int http_minor_version; | |
19 char *fields[HTTP_FIELD_MAX]; | |
20 int field_nb; | |
21 char *field_search; | |
22 int search_pos; | |
23 char *body; | |
24 int body_size; | |
902 | 25 char *buffer; |
26 int buffer_size; | |
27 int is_parsed; | |
870 | 28 } HTTP_header_t; |
29 | |
30 HTTP_header_t* http_new_header(); | |
31 void http_free( HTTP_header_t *http_hdr ); | |
902 | 32 int http_response_append( HTTP_header_t *http_hdr, char *data, int length ); |
33 int http_response_parse( HTTP_header_t *http_hdr ); | |
2489
0ecc1b4f7cf8
Added ASF http server streaming (Not mms streaming).
bertrand
parents:
2310
diff
changeset
|
34 int http_is_header_entire( HTTP_header_t *http_hdr ); |
902 | 35 char* http_build_request( HTTP_header_t *http_hdr ); |
870 | 36 char* http_get_field( HTTP_header_t *http_hdr, const char *field_name ); |
37 char* http_get_next_field( HTTP_header_t *http_hdr ); | |
38 void http_set_field( HTTP_header_t *http_hdr, const char *field ); | |
39 void http_set_method( HTTP_header_t *http_hdr, const char *method ); | |
40 void http_set_uri( HTTP_header_t *http_hdr, const char *uri ); | |
41 | |
42 void http_debug_hdr( HTTP_header_t *http_hdr ); | |
43 | |
44 #endif // __HTTP_H |