jmeter-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fschumac...@apache.org
Subject svn commit: r1780464 - /jmeter/trunk/src/core/org/apache/jmeter/JMeter.java
Date Thu, 26 Jan 2017 20:05:50 GMT
Author: fschumacher
Date: Thu Jan 26 20:05:50 2017
New Revision: 1780464

URL: http://svn.apache.org/viewvc?rev=1780464&view=rev
Log:
Use StandardCharset instead of looking one up by string.

Modified:
    jmeter/trunk/src/core/org/apache/jmeter/JMeter.java

Modified: jmeter/trunk/src/core/org/apache/jmeter/JMeter.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/JMeter.java?rev=1780464&r1=1780463&r2=1780464&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/JMeter.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/JMeter.java Thu Jan 26 20:05:50 2017
@@ -30,7 +30,7 @@ import java.net.DatagramSocket;
 import java.net.InetAddress;
 import java.net.MalformedURLException;
 import java.net.SocketException;
-import java.nio.charset.Charset;
+import java.nio.charset.StandardCharsets;
 import java.text.SimpleDateFormat;
 import java.util.Collection;
 import java.util.Date;
@@ -565,7 +565,7 @@ public class JMeter implements JMeterPlu
     private void displayAsciiArt() {
         try (InputStream inputStream = JMeter.class.getResourceAsStream("jmeter_as_ascii_art.txt"))
{
             if(inputStream != null) {
-                String text = IOUtils.toString(inputStream, Charset.forName("UTF-8"));
+                String text = IOUtils.toString(inputStream, StandardCharsets.UTF_8);
                 System.out.println(text);//NOSONAR
             }
         } catch (Exception e1) { //NOSONAR No logging here



Mime
View raw message