Re: Findbug exclusions
Hi Chris, found just one duplication: Match Class name=org.apache.fop.afp.AFPPaintingState/ Field name=colorConverter/ Bug pattern=SE_BAD_FIELD_STORE/ /Match using following template: xsl:template match=Match xsl:if test=preceding-sibling::Match[ Class/@name = current()/Class/@name and Field/@name = current()/Field/@name and Bug/@pattern = current()/Bug/@pattern] xsl:copy-of select=./ /xsl:if /xsl:template HTH, Le 18/01/2012 18:07, Chris Bowditch a écrit : On 18/01/2012 15:51, Glenn Adams wrote: I recall that someone (Jeremias or Simon?) had mechanically generated some exclusions to add to this file. It is possible that duplicates got inserted in that process. I know of no reason to retain duplicates. Thanks Glenn. I've removed the duplicates that I noticed initially, but I can see there are some more. Due to the size of the file, it will probably require some automated process to remove all the duplicates. Thanks, Chris On Wed, Jan 18, 2012 at 6:39 AM, Chris Bowditch bowditch_ch...@hotmail.com mailto:bowditch_ch...@hotmail.com wrote: Hi Fellow Committers, I was reviewing the current set of warnings generated by FindBugs and found myself needing to add an extra exclusion. I noticed that the exclusions file contains a lot of duplicates, e.g. Match Class name=org.apache.fop.render.afp.AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters/ Bug pattern=BC_UNCONFIRMED_CAST/ /Match Match Class name=org.apache.fop.render.afp.AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters/ Bug pattern=BC_UNCONFIRMED_CAST/ /Match Does anyone know why the duplicates exist? I confirmed that removing the duplicates does not re-introduce any warnings with FindBugs 1.3.9. Thanks, Chris -- Pascal
Re: Findbug exclusions
Hmm, I 've done it too fast. xsl:template match=Match xsl:if test=preceding-sibling::Match[ Class/@name = current()/Class/@name and Bug/@pattern = current()/Bug/@pattern and (Field/@name = current()/Field/@name or Method/@name = current()/Method/@name or (not(Method) and not(current()/Method) and not(Field) and not(current()/Field)))] xsl:copy-of select=./ /xsl:if /xsl:template This gives a more complete list (see atteched output) Le 19/01/2012 13:33, Pascal Sancho a écrit : Hi Chris, found just one duplication: Match Class name=org.apache.fop.afp.AFPPaintingState/ Field name=colorConverter/ Bug pattern=SE_BAD_FIELD_STORE/ /Match using following template: xsl:template match=Match xsl:if test=preceding-sibling::Match[ Class/@name = current()/Class/@name and Field/@name = current()/Field/@name and Bug/@pattern = current()/Bug/@pattern] xsl:copy-of select=./ /xsl:if /xsl:template HTH, Le 18/01/2012 18:07, Chris Bowditch a écrit : On 18/01/2012 15:51, Glenn Adams wrote: I recall that someone (Jeremias or Simon?) had mechanically generated some exclusions to add to this file. It is possible that duplicates got inserted in that process. I know of no reason to retain duplicates. Thanks Glenn. I've removed the duplicates that I noticed initially, but I can see there are some more. Due to the size of the file, it will probably require some automated process to remove all the duplicates. Thanks, Chris On Wed, Jan 18, 2012 at 6:39 AM, Chris Bowditch bowditch_ch...@hotmail.com mailto:bowditch_ch...@hotmail.com wrote: Hi Fellow Committers, I was reviewing the current set of warnings generated by FindBugs and found myself needing to add an extra exclusion. I noticed that the exclusions file contains a lot of duplicates, e.g. Match Class name=org.apache.fop.render.afp.AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters/ Bug pattern=BC_UNCONFIRMED_CAST/ /Match Match Class name=org.apache.fop.render.afp.AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters/ Bug pattern=BC_UNCONFIRMED_CAST/ /Match Does anyone know why the duplicates exist? I confirmed that removing the duplicates does not re-introduce any warnings with FindBugs 1.3.9. Thanks, Chris -- Pascal ?xml version=1.0 encoding=UTF-8? FindBugsFilter Match Class name=java.net.URLClassLoader/ !--Neither method nor field-- Bug pattern=DP_CREATE_CLASSLOADER_INSIDE_DO_PRIVILEGED/ /Match Match Class name=org.apache.fop.afp.AFPPaintingState/ Field name=colorConverter/ Bug pattern=SE_BAD_FIELD_STORE/ /Match Match Class name=org.apache.fop.hyphenation.ByteVector/ Method name=lt;initgt;/ Bug pattern=EI_EXPOSE_REP2/ /Match Match Class name=org.apache.fop.hyphenation.CharVector/ Method name=lt;initgt;/ Bug pattern=EI_EXPOSE_REP2/ /Match Match Class name=org.apache.fop.pdf.StreamCacheFactory/ Method name=getInstance/ Bug pattern=LI_LAZY_INIT_STATIC/ /Match Match Class name=org.apache.fop.fo.properties.NumberProperty/ Method name=lt;initgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fo.properties.NumberProperty/ Method name=lt;initgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fonts.CIDSubset/ Method name=mapSubsetChar/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fonts.base14.Helvetica/ Method name=lt;clinitgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fonts.base14.HelveticaBold/ Method name=lt;clinitgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fonts.base14.HelveticaBoldOblique/ Method name=lt;clinitgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fonts.base14.HelveticaOblique/ Method name=lt;clinitgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fonts.base14.TimesBold/ Method name=lt;clinitgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fonts.base14.TimesBoldItalic/ Method name=lt;clinitgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fonts.base14.TimesItalic/ Method name=lt;clinitgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fonts.base14.TimesRoman/ Method name=lt;clinitgt;/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.render.ps.PSDocumentHandler/ Method name=startPage/ Bug pattern=DM_NUMBER_CTOR/ /Match Match Class name=org.apache.fop.fo.flow.Footnote/ Method
Re: Findbug exclusions
On 19/01/2012 13:21, Pascal Sancho wrote: Hi Pascal, Many thanks for writing the below XSLT. That helped me eliminate the remaining duplicates. As the list wasn't too long it was easy enough to remove the duplicates by hand. Thanks, Chris Hmm, I 've done it too fast. xsl:template match=Match xsl:if test=preceding-sibling::Match[ Class/@name = current()/Class/@name and Bug/@pattern = current()/Bug/@pattern and (Field/@name = current()/Field/@name or Method/@name = current()/Method/@name or (not(Method) and not(current()/Method) and not(Field) and not(current()/Field)))] xsl:copy-of select=./ /xsl:if /xsl:template This gives a more complete list (see atteched output) Le 19/01/2012 13:33, Pascal Sancho a écrit : Hi Chris, found just one duplication: Match Class name=org.apache.fop.afp.AFPPaintingState/ Field name=colorConverter/ Bug pattern=SE_BAD_FIELD_STORE/ /Match using following template: xsl:template match=Match xsl:if test=preceding-sibling::Match[ Class/@name = current()/Class/@name and Field/@name = current()/Field/@name and Bug/@pattern = current()/Bug/@pattern] xsl:copy-of select=./ /xsl:if /xsl:template HTH, Le 18/01/2012 18:07, Chris Bowditch a écrit : On 18/01/2012 15:51, Glenn Adams wrote: I recall that someone (Jeremias or Simon?) had mechanically generated some exclusions to add to this file. It is possible that duplicates got inserted in that process. I know of no reason to retain duplicates. Thanks Glenn. I've removed the duplicates that I noticed initially, but I can see there are some more. Due to the size of the file, it will probably require some automated process to remove all the duplicates. Thanks, Chris On Wed, Jan 18, 2012 at 6:39 AM, Chris Bowditch bowditch_ch...@hotmail.commailto:bowditch_ch...@hotmail.com wrote: Hi Fellow Committers, I was reviewing the current set of warnings generated by FindBugs and found myself needing to add an extra exclusion. I noticed that the exclusions file contains a lot of duplicates, e.g. Match Class name=org.apache.fop.render.afp.AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters/ Bug pattern=BC_UNCONFIRMED_CAST/ /Match Match Class name=org.apache.fop.render.afp.AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters/ Bug pattern=BC_UNCONFIRMED_CAST/ /Match Does anyone know why the duplicates exist? I confirmed that removing the duplicates does not re-introduce any warnings with FindBugs 1.3.9. Thanks, Chris
Re: Findbug exclusions
I recall that someone (Jeremias or Simon?) had mechanically generated some exclusions to add to this file. It is possible that duplicates got inserted in that process. I know of no reason to retain duplicates. On Wed, Jan 18, 2012 at 6:39 AM, Chris Bowditch bowditch_ch...@hotmail.comwrote: Hi Fellow Committers, I was reviewing the current set of warnings generated by FindBugs and found myself needing to add an extra exclusion. I noticed that the exclusions file contains a lot of duplicates, e.g. Match Class name=org.apache.fop.render.**afp.**AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters**/ Bug pattern=BC_UNCONFIRMED_CAST/** /Match Match Class name=org.apache.fop.render.**afp.**AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters**/ Bug pattern=BC_UNCONFIRMED_CAST/** /Match Does anyone know why the duplicates exist? I confirmed that removing the duplicates does not re-introduce any warnings with FindBugs 1.3.9. Thanks, Chris
Re: Findbug exclusions
On 18/01/2012 15:51, Glenn Adams wrote: I recall that someone (Jeremias or Simon?) had mechanically generated some exclusions to add to this file. It is possible that duplicates got inserted in that process. I know of no reason to retain duplicates. Thanks Glenn. I've removed the duplicates that I noticed initially, but I can see there are some more. Due to the size of the file, it will probably require some automated process to remove all the duplicates. Thanks, Chris On Wed, Jan 18, 2012 at 6:39 AM, Chris Bowditch bowditch_ch...@hotmail.com mailto:bowditch_ch...@hotmail.com wrote: Hi Fellow Committers, I was reviewing the current set of warnings generated by FindBugs and found myself needing to add an extra exclusion. I noticed that the exclusions file contains a lot of duplicates, e.g. Match Class name=org.apache.fop.render.afp.AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters/ Bug pattern=BC_UNCONFIRMED_CAST/ /Match Match Class name=org.apache.fop.render.afp.AFPImageHandlerRawCCITTFax/ Method name=setAdditionalParameters/ Bug pattern=BC_UNCONFIRMED_CAST/ /Match Does anyone know why the duplicates exist? I confirmed that removing the duplicates does not re-introduce any warnings with FindBugs 1.3.9. Thanks, Chris