|
|
@ -53,6 +53,7 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
|
|
|
|
#include "asterisk/strings.h"
|
|
|
|
#include "asterisk/strings.h"
|
|
|
|
#include "asterisk/options.h"
|
|
|
|
#include "asterisk/options.h"
|
|
|
|
#include "asterisk/config.h"
|
|
|
|
#include "asterisk/config.h"
|
|
|
|
|
|
|
|
#include "asterisk/version.h"
|
|
|
|
|
|
|
|
|
|
|
|
#define MAX_PREFIX 80
|
|
|
|
#define MAX_PREFIX 80
|
|
|
|
#define DEFAULT_PREFIX "/asterisk"
|
|
|
|
#define DEFAULT_PREFIX "/asterisk"
|
|
|
@ -477,7 +478,7 @@ static void *ast_httpd_helper_thread(void *data)
|
|
|
|
time(&t);
|
|
|
|
time(&t);
|
|
|
|
strftime(timebuf, sizeof(timebuf), "%a, %d %b %Y %H:%M:%S GMT", gmtime(&t));
|
|
|
|
strftime(timebuf, sizeof(timebuf), "%a, %d %b %Y %H:%M:%S GMT", gmtime(&t));
|
|
|
|
ast_cli(ser->fd, "HTTP/1.1 %d %s\r\n", status, title ? title : "OK");
|
|
|
|
ast_cli(ser->fd, "HTTP/1.1 %d %s\r\n", status, title ? title : "OK");
|
|
|
|
ast_cli(ser->fd, "Server: Asterisk\r\n");
|
|
|
|
ast_cli(ser->fd, "Server: Asterisk/%s\r\n", ASTERISK_VERSION);
|
|
|
|
ast_cli(ser->fd, "Date: %s\r\n", timebuf);
|
|
|
|
ast_cli(ser->fd, "Date: %s\r\n", timebuf);
|
|
|
|
ast_cli(ser->fd, "Connection: close\r\n");
|
|
|
|
ast_cli(ser->fd, "Connection: close\r\n");
|
|
|
|
if (contentlength) {
|
|
|
|
if (contentlength) {
|
|
|
|