Re: 7.1.1 upload with zero file size
Greg Huber <[email protected]> Thu, 2 Oct 2025 09:59:04 +0100
| Newsgroups | gmane.comp.jakarta.struts.devel |
|---|---|
| Message-ID | <[email protected]> |
>> Do you have <s:actionerrors/> and <s:fielderrors> tags used?
I do, but only declared once, I have checked the page.
###
Logging from here, I can see its duplicating the interceptor calls, ie
this is being called twice.
DefaultActionInvocation
protectedStringexecuteConditional(ConditionalInterceptorconditionalInterceptor)throwsException{
if(conditionalInterceptor.shouldIntercept(this)){
LOG.debug("Executing conditional interceptor:
{}",conditionalInterceptor.getClass().getSimpleName());
System.out.println(conditionalInterceptor.getClass().getSimpleName());
returnconditionalInterceptor.intercept(this);
}else{
LOG.debug("Interceptor: {} is disabled, skipping to
next",conditionalInterceptor.getClass().getSimpleName());
returnthis.invoke();
}
}
DataUrlInterceptor
ExceptionMappingInterceptor
ServletConfigInterceptor
ChainingInterceptor
ActionFileUploadInterceptor
CheckboxInterceptor
MultiselectInterceptor
ActionMappingParametersInterceptor
ParametersInterceptor
StrutsConversionErrorInterceptor
DefaultWorkflowInterceptor
DataUrlInterceptor
ExceptionMappingInterceptor
ServletConfigInterceptor
ChainingInterceptor
ActionFileUploadInterceptor
CheckboxInterceptor
MultiselectInterceptor
ActionMappingParametersInterceptor
ParametersInterceptor
StrutsConversionErrorInterceptor
DefaultWorkflowInterceptor
When I refresh the action/page I only get one set.
Also, I definitely only have one
<interceptor-ref name="actionFileUpload" />
in my struts.xml.
On 02/10/2025 09:47, Lukasz Lenart wrote:
> czw., 2 paź 2025 o 10:03 Greg Huber<[email protected]> napisał(a):
>> When testing with a zero file size, I get two action error messages:
>>
>> * File zero-filesize-test.gif for field uploadedFiles is empty (0
>> bytes). Empty file uploads are not allowed.
>> * File zero-filesize-test.gif for field uploadedFiles is empty (0
>> bytes). Empty file uploads are not allowed.
>>
>> I have checked my actions and cannot find any duplication.
> Do you have <s:actionerrors/> and <s:fielderrors> tags used?
>
>
> Cheers
> Łukasz
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:[email protected]
> For additional commands, e-mail:[email protected]
>