Diff for /parser3/src/targets/isapi/parser3isapi.C between versions 1.28 and 1.35

version 1.28, 2001/04/10 10:32:13 version 1.35, 2001/06/28 07:44:17
Line 1 Line 1
   /** @file
           Parser: IIS extension.
   
           Copyright (c) 2000,2001 ArtLebedev Group (http://www.artlebedev.com)
   
           Author: Alexander Petrosyan <paf@design.ru> (http://design.ru/paf)
   */
   static const char *RCSId="$Id$"; 
   
 #ifndef _MSC_VER  #ifndef _MSC_VER
 #       error compile ISAPI module with MSVC [no urge for now to make it autoconf-ed (PAF)]  #       error compile ISAPI module with MSVC [no urge for now to make it autoconf-ed (PAF)]
 #endif  #endif
Line 109  void SAPI::add_header_attribute(Pool& po Line 118  void SAPI::add_header_attribute(Pool& po
                 ctx.header->APPEND_CONST(key);                  ctx.header->APPEND_CONST(key);
                 ctx.header->APPEND_CONST(": ");                  ctx.header->APPEND_CONST(": ");
                 ctx.header->APPEND_CONST(value);                  ctx.header->APPEND_CONST(value);
                 ctx.header->APPEND_CONST("\n");                  ctx.header->APPEND_CONST("\r\n");
         }          }
 }  }
   
Line 118  void SAPI::send_header(Pool& pool) { Line 127  void SAPI::send_header(Pool& pool) {
         SAPI_func_context& ctx=*static_cast<SAPI_func_context *>(pool.context());          SAPI_func_context& ctx=*static_cast<SAPI_func_context *>(pool.context());
   
         ctx.header->APPEND_CONST(          ctx.header->APPEND_CONST(
                 "expires: Fri, 23 Mar 2001 09:32:23 GMT\n"                  "expires: Fri, 23 Mar 2001 09:32:23 GMT\r\n"
                 "\n");                  "\r\n");
         HSE_SEND_HEADER_EX_INFO header_info;          HSE_SEND_HEADER_EX_INFO header_info;
   
         char status_buf[MAX_STATUS_LENGTH];          char status_buf[MAX_STATUS_LENGTH];
Line 171  static bool parser_init() { Line 180  static bool parser_init() {
                 // init socks                  // init socks
                 init_socks(pool);                  init_socks(pool);
   
                   // init global classes
                   init_methoded_array(pool);
                 // init global variables                  // init global variables
                 pa_globals_init(pool);                  pa_globals_init(pool);
                                   
Line 260  DWORD WINAPI HttpExtensionProc(LPEXTENSI Line 271  DWORD WINAPI HttpExtensionProc(LPEXTENSI
                 // prepare to process request                  // prepare to process request
                 Request request(pool,                  Request request(pool,
                         request_info,                          request_info,
                         String::UL_HTML_TYPO                          String::UL_USER_HTML
                         );                          );
   
                 // some root-controlled location                  // some root-controlled location
Line 279  DWORD WINAPI HttpExtensionProc(LPEXTENSI Line 290  DWORD WINAPI HttpExtensionProc(LPEXTENSI
         } PCATCH(e) { // global problem          } PCATCH(e) { // global problem
                 // don't allocate anything on pool here:                  // don't allocate anything on pool here:
                 //   possible pool' exception not catch-ed now                  //   possible pool' exception not catch-ed now
                 //   and there could be out-of-memory exception                          //   and there could be out-of-memory exception
                 const char *body=e.comment();                  const char *body=e.comment();
                 // log it                  // log it
                 SAPI::log(pool, "exception in request exception handler: %s", body);                  SAPI::log(pool, "exception in request exception handler: %s", body);
Line 290  DWORD WINAPI HttpExtensionProc(LPEXTENSI Line 301  DWORD WINAPI HttpExtensionProc(LPEXTENSI
                 // prepare header // not using SAPI func wich allocates on pool                  // prepare header // not using SAPI func wich allocates on pool
                 char header_buf[MAX_STRING];                  char header_buf[MAX_STRING];
                 int header_len=snprintf(header_buf, MAX_STRING,                  int header_len=snprintf(header_buf, MAX_STRING,
                         "content-type: text/plain\n"                          "content-type: text/plain\r\n"
                         "content-length: %lu\n"                          "content-length: %lu\r\n"
                         "expires: Fri, 23 Mar 2001 09:32:23 GMT\n"                          "expires: Fri, 23 Mar 2001 09:32:23 GMT\r\n"
                         "\n",                          "\r\n",
                         content_length);                          content_length);
   
                 HSE_SEND_HEADER_EX_INFO header_info;                  HSE_SEND_HEADER_EX_INFO header_info;

Removed from v.1.28  
changed lines
  Added in v.1.35


E-mail: