Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 360AC200B9A for ; Fri, 7 Oct 2016 18:21:19 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 34E44160AE8; Fri, 7 Oct 2016 16:21:19 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 7B175160AC6 for ; Fri, 7 Oct 2016 18:21:18 +0200 (CEST) Received: (qmail 87012 invoked by uid 500); 7 Oct 2016 16:21:17 -0000 Mailing-List: contact commits-help@pdfbox.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@pdfbox.apache.org Delivered-To: mailing list commits@pdfbox.apache.org Received: (qmail 87003 invoked by uid 99); 7 Oct 2016 16:21:17 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 07 Oct 2016 16:21:17 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 579701A021B for ; Fri, 7 Oct 2016 16:21:17 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -1.999 X-Spam-Level: X-Spam-Status: No, score=-1.999 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-2.999] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id 43_O8pZWXSZv for ; Fri, 7 Oct 2016 16:21:16 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id 835905FB0B for ; Fri, 7 Oct 2016 16:21:16 +0000 (UTC) Received: from svn01-us-west.apache.org (svn.apache.org [10.41.0.6]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 0132FE0099 for ; Fri, 7 Oct 2016 16:21:16 +0000 (UTC) Received: from svn01-us-west.apache.org (localhost [127.0.0.1]) by svn01-us-west.apache.org (ASF Mail Server at svn01-us-west.apache.org) with ESMTP id F018F3A039C for ; Fri, 7 Oct 2016 16:21:15 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1763795 - /pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/common/function/type4/InstructionSequenceBuilder.java Date: Fri, 07 Oct 2016 16:21:15 -0000 To: commits@pdfbox.apache.org From: tilman@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20161007162115.F018F3A039C@svn01-us-west.apache.org> archived-at: Fri, 07 Oct 2016 16:21:19 -0000 Author: tilman Date: Fri Oct 7 16:21:15 2016 New Revision: 1763795 URL: http://svn.apache.org/viewvc?rev=1763795&view=rev Log: PDFBOX-2852: don't reassign parameter, as suggested by scotty1024 in github PR 6 Modified: pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/common/function/type4/InstructionSequenceBuilder.java Modified: pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/common/function/type4/InstructionSequenceBuilder.java URL: http://svn.apache.org/viewvc/pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/common/function/type4/InstructionSequenceBuilder.java?rev=1763795&r1=1763794&r2=1763795&view=diff ============================================================================== --- pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/common/function/type4/InstructionSequenceBuilder.java (original) +++ pdfbox/branches/2.0/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/common/function/type4/InstructionSequenceBuilder.java Fri Oct 7 16:21:15 2016 @@ -114,11 +114,8 @@ public final class InstructionSequenceBu */ public static int parseInt(String token) { - if (token.startsWith("+")) - { - token = token.substring(1); - } - return Integer.parseInt(token); + //TODO Beginning with JDK7 Integer.parseInt accepts leading +'s + return Integer.parseInt(token.startsWith("+") ? token.substring(1) : token); } /**