[luci] [BUG] LuCI checkbox parsing

Jouke Witteveen j.witteveen at gmail.com
Wed Jul 29 15:50:40 CEST 2009


Dear sir,

I think to have stumbled upon a bug in LuCI's parsing of checkboxes.
As far as I can see it is introduced with the reparsing first found in
Changeset 2696 (2008, July 30).

Since the commit before the reparsing changes the section names,
subsequent calls to any formvalue function are deemed to return nil.
For checkboxes this is a problem, because nil is also the value
returned for unchecked checkboxes. The result is that Flag.parse
cannot distinguish between unchecking and reparsing (strictly
speaking: not in a stateless manner) and will raise an unckecking even
(calling the write method) after it has been checked before!
This situation occurs when the LuCI application also contains other
fields that are changed in the submit.

This report is sent to you personally because I do not have permission
to open tickets in the LuCI track, nor am I a member of the
mailinglist.

Thanks for your efforts,
Jouke Witteveen


More information about the luci mailing list