--- parser3/src/main/pa_request.C 2005/11/21 11:23:07 1.274.6.3 +++ parser3/src/main/pa_request.C 2005/12/13 11:00:55 1.278.2.1 @@ -5,7 +5,7 @@ Author: Alexandr Petrosian (http://paf.design.ru) */ -static const char * const IDENT_REQUEST_C="$Date: 2005/11/21 11:23:07 $"; +static const char * const IDENT_REQUEST_C="$Date: 2005/12/13 11:00:55 $"; #include "pa_sapi.h" #include "pa_common.h" @@ -495,6 +495,7 @@ frame.store_param(*new VTable(&stack_tra // future $response:body= // execute ^unhandled_exception[exception;stack] +exception_trace.clear(); // forget all about previous life, in case there would be error inside of this method, error handled would not be mislead by old stack contents (see extract_origin) body_string=&execute_method(frame, *method).as_string(); } } @@ -559,12 +560,12 @@ void Request::use_file(VStateless_class& file_spec=0; if(Value* element=main_class.get_element(class_path_name, main_class, false)) { if(element->is_string()) { - file_spec=file_readable(absolute(element->as_string()), file_name); // found at class_path? + file_spec=file_exist(absolute(element->as_string()), file_name); // found at class_path? } else if(Table *table=element->get_table()) { int size=table->count(); for(int i=size; i--; ) { const String& path=*(*table->get(i))[0]; - if((file_spec=file_readable(absolute(path), file_name))) + if((file_spec=file_exist(absolute(path), file_name))) break; // found along class_path } } else @@ -937,13 +938,15 @@ const Request::Trace Request::Exception_ if(!is_empty()) { result=bottom_value(); if(!problem_source) { // we don't know who trigged the bug? - problem_source=result.name(); // consider the stack-top-guy did that + problem_source=result.name(); // consider the stack-top-guy (we usually know source of next-from-throw-point exception) did that fbottom++; } else if(result.name()==problem_source) // it is that same guy? fbottom++; // throw away that trace - // else stack top contains not us, - // leaving result intact - // it would help ^throw + else { + // stack top contains not us, + // leaving result intact + // it would help ^throw + } } return result;