Diff for /parser3/src/main/pa_globals.C between versions 1.145 and 1.150

version 1.145, 2002/11/27 12:44:35 version 1.150, 2003/01/15 10:34:51
Line 32  extern "C" { Line 32  extern "C" {
 String *content_type_name;  String *content_type_name;
 String *charset_name;  String *charset_name;
 String *body_name;  String *body_name;
   String *download_name;
 String *value_name;  String *value_name;
 String *expires_name;  String *expires_name;
 String *path_name;  String *path_name;
Line 257  xmlFileOpenLocalhost (const char *filena Line 258  xmlFileOpenLocalhost (const char *filena
  * Returns the number of bytes written   * Returns the number of bytes written
  */   */
 static int  static int
 xmlFileRead (void * context, char * buffer, int len) {  pa_xmlFileRead (void * context, char * buffer, int len) {
     return(fread(&buffer[0], 1,  len, (FILE *) context));      return(fread(&buffer[0], 1,  len, (FILE *) context));
 }  }
   
 /**  /**
  * xmlFileWrite:  
  * @context:  the I/O context  
  * @buffer:  where to drop data  
  * @len:  number of bytes to write  
  *  
  * Write @len bytes from @buffer to the I/O channel.  
  *  
  * Returns the number of bytes written  
  */  
 static int  
 xmlFileWrite (void * context, const char * buffer, int len) {  
     return(fwrite(&buffer[0], 1,  len, (FILE *) context));  
 }  
   
 /**  
  * xmlFileClose:   * xmlFileClose:
  * @context:  the I/O context   * @context:  the I/O context
  *   *
  * Close an I/O channel   * Close an I/O channel
  */   */
 static int  static int
 xmlFileClose (void * context) {  pa_xmlFileClose (void * context) {
     return ( ( fclose((FILE *) context) == EOF ) ? -1 : 0 );      return ( ( fclose((FILE *) context) == EOF ) ? -1 : 0 );
 }  }
   
Line 319  void pa_globals_init(Pool& pool) { Line 305  void pa_globals_init(Pool& pool) {
         content_type_name=NEW String(pool, CONTENT_TYPE_NAME);          content_type_name=NEW String(pool, CONTENT_TYPE_NAME);
         charset_name=NEW String(pool, CHARSET_NAME);          charset_name=NEW String(pool, CHARSET_NAME);
         body_name=NEW String(pool, BODY_NAME);          body_name=NEW String(pool, BODY_NAME);
           download_name=NEW String(pool, DOWNLOAD_NAME);
         value_name=NEW String(pool, VALUE_NAME);          value_name=NEW String(pool, VALUE_NAME);
         expires_name=NEW String(pool, EXPIRES_NAME);          expires_name=NEW String(pool, EXPIRES_NAME);
         path_name=NEW String(pool, PATH_NAME);          path_name=NEW String(pool, PATH_NAME);
Line 380  void pa_globals_init(Pool& pool) { Line 367  void pa_globals_init(Pool& pool) {
         #define ULN(cstr, LANG) \          #define ULN(cstr, LANG) \
                 untaint_lang_name2enum->put(*NEW String(pool, cstr), (int)String::UL_##LANG);                  untaint_lang_name2enum->put(*NEW String(pool, cstr), (int)String::UL_##LANG);
         ULN("as-is", AS_IS);          ULN("as-is", AS_IS);
           ULN("optimized-as-is", AS_IS|String::UL_OPTIMIZE_BIT);
         ULN("file-spec", FILE_SPEC);          ULN("file-spec", FILE_SPEC);
         ULN("http-header", HTTP_HEADER);          ULN("http-header", HTTP_HEADER);
         ULN("mail-header", MAIL_HEADER);          ULN("mail-header", MAIL_HEADER);
Line 388  void pa_globals_init(Pool& pool) { Line 376  void pa_globals_init(Pool& pool) {
         ULN("sql", SQL);          ULN("sql", SQL);
         ULN("js", JS);          ULN("js", JS);
         ULN("xml", XML);          ULN("xml", XML);
           ULN("optimized-xml", XML|String::UL_OPTIMIZE_BIT);
         ULN("html", HTML);          ULN("html", HTML);
         ULN("optimized-html", HTML|String::UL_OPTIMIZE_BIT);          ULN("optimized-html", HTML|String::UL_OPTIMIZE_BIT);
   
Line 584  void pa_globals_init(Pool& pool) { Line 573  void pa_globals_init(Pool& pool) {
         // http://localhost/abc -> $ENV{DOCUMENT_ROOT}/abc | ./abc          // http://localhost/abc -> $ENV{DOCUMENT_ROOT}/abc | ./abc
         xmlRegisterInputCallbacks(          xmlRegisterInputCallbacks(
                 xmlFileMatchLocalhost, xmlFileOpenLocalhost,                  xmlFileMatchLocalhost, xmlFileOpenLocalhost,
                 xmlFileRead, xmlFileClose);                  pa_xmlFileRead, pa_xmlFileClose);
   
         // XSLT stylesheet manager          // XSLT stylesheet manager
         cache_managers->put(*NEW String(pool, "stylesheet"),           cache_managers->put(*NEW String(pool, "stylesheet"), 

Removed from v.1.145  
changed lines
  Added in v.1.150


E-mail: