<AWT Dev> RFR [16] 8246248: TransferHandler.exportToClipboard prints stacktrace even if succeeded

Philip Race philip.race at oracle.com
Mon Jul 20 22:35:47 UTC 2020


PS I also don't think statically initialising a logger even if it is 
never needed is a good idea.

-phil.

On 7/20/20, 9:04 AM, Philip Race wrote:
> No, not approved. This fix is using sun.util from inside Java,base.
> We need to remove the existing cases of this usage. Not add new ones.
>
> -phil.
>
> On 7/20/20, 8:53 AM, Sergey Bylokhov wrote:
>>
>>
>> Firstly, as the issue was observed with JPEG flavor with alpha 
>> component, I have tested with regular JPEG image (without alpha) and 
>> the image was copied onto the clipboard and no exception was thrown 
>> as expected.
>>
>> Secondly, tested with JPEG flavor with alpha, there was no JPEG 
>> flavor copied onto the clipboard as the support was removed/dropped 
>> and the IOException is thrown as expected and is logged into the 
>> logger (seen after enabling the logging). Please find the attached 
>> file for reference. Please search for the log message "WARNING: 
>> Registered service providers failed to encode".
>>
>> Also, there are datatransfer tests available which was run and there 
>> were no new failures observed.
>>
>> This fix doesn't change any of the functionalities rather, cleans up 
>> the code and logs the exception to the logger instead of printing the 
>> same on the console.
>>
>> Best Regards,
>> K Suman Rajkumaar 


More information about the awt-dev mailing list