Modify

Opened 6 years ago

Closed 6 years ago

#15505 closed enhancement (fixed)

Update com.drew.metadata sourcecode to current GitHub code

Reported by: naoliv Owned by: Don-vip
Priority: normal Milestone: 17.11
Component: Core Version:
Keywords: Cc:

Description

length is always > 16, so we don't need to test if it's == 1:

  • src/com/drew/metadata/TagDescriptor.java

     
    7373        if (object.getClass().isArray()) {
    7474            final int length = Array.getLength(object);
    7575            if (length > 16) {
    76                 return String.format("[%d %s]", length, length == 1 ? "value" : "values");
     76                return String.format("[%d values]", length);
    7777            }
    7878        }

Attachments (0)

Change History (7)

comment:1 by Don-vip, 6 years ago

Did you find this yourself, or do you ask us to backport https://github.com/drewnoakes/metadata-extractor/commit/a101da7e051bc03d2f06ab69dd5c4c63e7597c9d#diff-5e6af2075900c3b1cc5713d461008f95 ?

It's better to simply update the whole source code :)

comment:2 by Don-vip, 6 years ago

Milestone: 17.11

comment:3 by naoliv, 6 years ago

Hum... only now I am seeing that it's an external source.
I was trying to spot low hanging fruits in the code with IntelliJ.

Last edited 6 years ago by naoliv (previous) (diff)

comment:4 by Don-vip, 6 years ago

JOSM fruits must hang higher then, this is a good sign :)

comment:5 by stoecker, 6 years ago

Summary: [PATCH] simplify test for long arrays in TagDescriptor.javaUpdate com.drew.metadata sourcecode to current GitHub code

comment:6 by Don-vip, 6 years ago

Owner: changed from team to Don-vip
Status: newassigned

comment:7 by Don-vip, 6 years ago

Resolution: fixed
Status: assignedclosed

In 13061/josm:

fix #15505 - update to metadata-extractor 2.10.1

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Don-vip.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.