X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=http_api.c;h=7825ebdd353ebd57aaf3098577d1bff821106e66;hb=76ef3c1710bd22c560f9459f00452050d72f44db;hp=6046052f1be597943442acb832b0109d00ea4b62;hpb=32e91737086db53bb1fd9ed9f79d693c43ec459f;p=m6w6%2Fext-http diff --git a/http_api.c b/http_api.c index 6046052..7825ebd 100644 --- a/http_api.c +++ b/http_api.c @@ -206,9 +206,7 @@ void _http_log_ex(char *file, const char *ident, const char *message TSRMLS_DC) { time_t now; struct tm nowtm; - char datetime[128]; - - HTTP_CHECK_OPEN_BASEDIR(file, return); + char datetime[20] = {0}; time(&now); strftime(datetime, sizeof(datetime), "%Y-%m-%d %H:%M:%S", php_localtime_r(&now, &nowtm)); @@ -256,6 +254,7 @@ STATUS _http_exit_ex(int status, char *header, char *body, zend_bool send_header case 301: http_log(HTTP_G(log).redirect, "301-REDIRECT", header); break; case 302: http_log(HTTP_G(log).redirect, "302-REDIRECT", header); break; case 303: http_log(HTTP_G(log).redirect, "303-REDIRECT", header); break; + case 305: http_log(HTTP_G(log).redirect, "305-REDIRECT", header); break; case 307: http_log(HTTP_G(log).redirect, "307-REDIRECT", header); break; case 304: http_log(HTTP_G(log).cache, "304-CACHE", header); break; case 405: http_log(HTTP_G(log).allowed_methods, "405-ALLOWED", header); break;