Diff for /parser3/src/classes/op.C between versions 1.190 and 1.193

version 1.190, 2009/07/06 12:13:30 version 1.193, 2009/07/07 12:25:36
Line 88  public: Line 88  public:
                 ULN("html", HTML);                  ULN("html", HTML);
                 ULN("optimized-html", HTML|String::L_OPTIMIZE_BIT);                  ULN("optimized-html", HTML|String::L_OPTIMIZE_BIT);
                 ULN("regex", REGEX);                  ULN("regex", REGEX);
                   ULN("parser-code", PARSER_CODE);
                 #undef ULN                  #undef ULN
         }          }
 } untaint_lang_name2enum;  } untaint_lang_name2enum;
Line 122  static void _untaint(Request& r, MethodP Line 123  static void _untaint(Request& r, MethodP
         {          {
                 Value& vbody=params.as_junction(params.count()-1, "body must be code");                  Value& vbody=params.as_junction(params.count()-1, "body must be code");
                                   
                 StringOrValue result;                  Temp_lang temp_lang(r, lang); // set temporarily specified ^untaint[language;
                 {                  StringOrValue result=r.process(vbody); // process marking tainted with that lang
                         Temp_lang temp_lang(r, lang); // set temporarily specified ^untaint[language;  
                         result=r.process(vbody); // process marking tainted with that lang  
                 }  
                 r.write_assign_lang(result);                  r.write_assign_lang(result);
         }          }
 }  }
Line 141  static void _taint(Request& r, MethodPar Line 139  static void _taint(Request& r, MethodPar
         {          {
                 Value& vbody=params.as_no_junction(params.count()-1, "body must not be code");                  Value& vbody=params.as_no_junction(params.count()-1, "body must not be code");
                                   
                 String result;                  String result(vbody.as_string(), lang); // force result language to specified
                 result.append(  
                         vbody.as_string(),  // process marking tainted with that lang  
                         lang, true);  // force result language to specified  
                 r.write_assign_lang(result);                  r.write_assign_lang(result);
         }          }
 }  }
Line 169  static void _process(Request& r, MethodP Line 164  static void _process(Request& r, MethodP
                                 "no target class");                                  "no target class");
   
                 // temporary remove language change                  // temporary remove language change
                 Temp_lang temp_lang(r, String::L_PASS_APPENDED);                  Temp_lang temp_lang(r, String::L_PARSER_CODE);
                 // temporary zero @main so to maybe-replace it in processed code                  // temporary zero @main so to maybe-replace it in processed code
                 Temp_method temp_method_main(*target_class, main_method_name, 0);                  Temp_method temp_method_main(*target_class, main_method_name, 0);
                 // temporary zero @auto so it wouldn't be auto-called in Request::use_buf                  // temporary zero @auto so it wouldn't be auto-called in Request::use_buf

Removed from v.1.190  
changed lines
  Added in v.1.193


E-mail: