http.c File Reference

A simple HTTP test. More...

Go to the source code of this file.

Defines

#define REQ_LENGTH   1024

Functions

int check_http (Port_T p)


Detailed Description

A simple HTTP test.

We send the following request to the server: 'GET / HTTP/1.1' ... if request statement isn't defined 'GET /custom/page HTTP/1.1' ... if request statement is defined and check the server's status code.

If the host statement defines hostname, it is used in 'Host:' header.

If the status code is >= 400, an error has occurred. Return TRUE if the status code is OK, otherwise FALSE.

Author:
Jan-Henrik Haukeland, <hauk@tildeslash.com> , Martin Pala, <martin.pala@hq.iol.cz>
Version:
$Id: http.c,v 1.15 2002/12/21 13:56:04 hauk Exp $

Definition in file http.c.


Define Documentation

#define REQ_LENGTH   1024
 


Function Documentation

int check_http Port_T    p
 

Definition at line 70 of file http.c.

References ASSERT, chomp(), log(), port_recv(), port_send(), prog, myport::request, STRERROR, and VERSION.