Foswiki on GitHub is open for business! Next release meeting: Monday September 15, 1300Z

Item2337: ATTACHFILESIZELIMIT check fails confusingly if value is "0 "

Priority: CurrentState: AppliesTo: Component: WaitingFor:
Normal Closed Engine UI/Upload  
If the user mistakenly sets ATTACHFILESIZELIMIT to the string "0 ", the file size check fails, but with a confusing error:

"Oversized file foo exceeds limit of 0  Kb.

Since there's no real visual clue that there's an extra space, this can cause some frustration. The attached patch strips trailing spaces from the value. I presume this is not done by the preference macro parsing code because trailing spaces might be useful in some contexts.

The UploadPlugin has the same issue.


Can't confirm the issue for UploadPlugin: Setting ATTACHFILESIZELIMIT to 0 disables the check all together.

-- MichaelDaum - 17 Nov 2009

Did you try the string "0 " (note the space at the end)?

-- DiabJerius - 16 Jan 2010

Was an easy fix. It is possible to add trailing spaces if you accidently edit a settings topic with Wysiwyg and the wrong browser so this is why I found it worth fixing in 1.0.9

-- KennethLavrsen - 17 Jan 2010

Re-opening because this has been fixed properly in the release branch, but the fix in trunk is wrong. So re-opening and fixing will NOT disrupt the release process, as this bug is closed, and has been closed for 1.0.9.

-- OlivierRaginel - 19 Jan 2010

ItemTemplate edit

Summary ATTACHFILESIZELIMIT check fails confusingly if value is "0 "
ReportedBy DiabJerius
Codebase 1.0.7
SVN Range Foswiki-1.0.7, Sun, 20 Sep 2009, build 5061
AppliesTo Engine
Component UI/Upload
Priority Normal
CurrentState Closed
WaitingFor
Checkins Foswikirev:6064 Foswikirev:6065 Foswikirev:6066 Foswikirev:6067 Foswikirev:6068 Foswikirev:6069 Foswikirev:6091
TargetRelease patch
ReleasedIn 1.0.9
Topic attachments
I Attachment Action Size Date Who Comment
attachsize.patchpatch attachsize.patch manage 0.4 K 07 Nov 2009 - 20:30 DiabJerius  
Topic revision: r12 - 19 Jan 2010, OlivierRaginel
 
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. see CopyrightStatement. Creative Commons License