[rfc][icedtea-web][policyeditor] NPE in filechanged check

Andrew Azores aazores at redhat.com
Wed Mar 12 15:36:57 UTC 2014


Hi,

Just noticed that there are conditions where an NPE will occur due to 
the new filechanged check. Steps to reproduce:
1) launch policyeditor with no arguments
2) create some set of permissions, eg Print Documents only, doesn't 
really matter so long as you make at least one change
3) press Apply
4) attempt to save the policy file to any location eg $HOME/test.policy
5) NPE will occur because there is no MD5SumWatcher reference, since no 
policy file was ever opened first
5b) file fails to save

With the patch applied, 5/5b does not occur, and instead the flow 
completes as expected with a "Changes saved" message, and the file can 
be verified as written to disk.

Thanks,

-- 
Andrew A

-------------- next part --------------
A non-text attachment was scrubbed...
Name: policyeditor-filechanged-npe.patch
Type: text/x-patch
Size: 1234 bytes
Desc: not available
URL: <http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20140312/3c07edc0/policyeditor-filechanged-npe.patch>


More information about the distro-pkg-dev mailing list