|
|
| version 1.3, 2001/03/19 21:39:30 | version 1.4, 2001/03/20 06:45:16 |
|---|---|
| Line 17 VStateless_class *file_class; | Line 17 VStateless_class *file_class; |
| // methods | // methods |
| static void _save(Request& r, const String& method_name, Array *params) { | static void _save(Request& r, const String& method_name, Array *params) { |
| //\Pool& pool=r.pool(); | Pool& pool=r.pool(); |
| Value *vfile_name=static_cast<Value *>(params->get(0)); | Value *vfile_name=static_cast<Value *>(params->get(0)); |
| // forcing | // forcing |
| // ^save{this body type} | // ^save[this body type] |
| r.fail_if_junction_(false, *vfile_name, method_name, "file name must be junction"); | r.fail_if_junction_(true, *vfile_name, |
| method_name, "file name must not be junction"); | |
| { | // forcing untaint language |
| Temp_lang temp_lang(r, String::Untaint_lang::FILE); | String lfile_name(pool); |
| static_cast<VFile *>(r.self)->save( | lfile_name.append(vfile_name->as_string(), |
| r.absolute(r.process(*vfile_name).as_string().cstr())); | String::Untaint_lang::FILE_NAME, true); |
| } | |
| static_cast<VFile *>(r.self)->save(r.absolute(lfile_name.cstr())); | |
| } | } |
| // initialize | // initialize |