--- parser3/src/classes/Attic/root.C 2001/03/18 16:32:24 1.43 +++ parser3/src/classes/Attic/root.C 2001/03/24 15:57:57 1.49 @@ -3,16 +3,16 @@ Copyright (c) 2001 ArtLebedev Group (http://www.artlebedev.com) Author: Alexander Petrosyan (http://design.ru/paf) - $Id: root.C,v 1.43 2001/03/18 16:32:24 paf Exp $ + $Id: root.C,v 1.49 2001/03/24 15:57:57 paf Exp $ */ -#include +#include "pa_config_includes.h" #include +#include "pa_common.h" #include "pa_request.h" #include "_root.h" #include "pa_vint.h" -#include "pa_common.h" static void _if(Request& r, const String& method_name, Array *params) { Value& condition_code=*static_cast(params->get(0)); @@ -73,9 +73,12 @@ static void _taint(Request& r, const Str r.fail_if_junction_(true, *vbody, method_name, "body must not be junction"); - Temp_lang temp_lang(r, String::Untaint_lang::AS_IS); // set temporarily as-is language - String result(r.process(*vbody).as_string()); // process marking tainted with that lang - result.change_lang(lang); // switch result language to specified + // set temporarily as-is language + Temp_lang temp_lang(r, String::UL_AS_IS); + String result(r.pool()); + result.append( + r.process(*vbody).as_string(), // process marking tainted with that lang + lang, true); // force result language to specified r.write_pass_lang(result); } } @@ -158,8 +161,7 @@ static void _use(Request& r, const Strin r.fail_if_junction_(true, vfile, method_name, "file name must not be junction"); - char *file=vfile.as_string().cstr(); - r.use_file(r.absolute(file)); + r.use_file(r.absolute(vfile.as_string())); } static void _for(Request& r, const String& method_name, Array *params) {