From: Olivier Lamy Date: Sun, 8 Jul 2012 16:12:21 +0000 (+0000) Subject: correctly intialize array size X-Git-Tag: redback-2.0~108 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=7f08b0cbabbf40461488dd6803c5dce23a88e879;p=archiva.git correctly intialize array size git-svn-id: https://svn.apache.org/repos/asf/archiva/redback/redback-core/trunk@1358772 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/redback-users/redback-users-providers/redback-users-jdo/src/main/java/org/apache/archiva/redback/users/jdo/JdoUserQuery.java b/redback-users/redback-users-providers/redback-users-jdo/src/main/java/org/apache/archiva/redback/users/jdo/JdoUserQuery.java index 77933e929..5cb873c09 100644 --- a/redback-users/redback-users-providers/redback-users-jdo/src/main/java/org/apache/archiva/redback/users/jdo/JdoUserQuery.java +++ b/redback-users/redback-users-providers/redback-users-jdo/src/main/java/org/apache/archiva/redback/users/jdo/JdoUserQuery.java @@ -105,7 +105,7 @@ public class JdoUserQuery keys.add( getEmail() ); } - return (String[]) keys.toArray( new String[0] ); + return keys.toArray( new String[keys.size()] ); } /**