]> WPIA git - gigi.git/blobdiff - tests/org/cacert/gigi/ping/TestHTTP.java
Fix: various coverity charset issues.
[gigi.git] / tests / org / cacert / gigi / ping / TestHTTP.java
index 64c9cd650e3e618d7c51cd194f3b70158554e7b1..6ee6f6e821cecc958eb2a338ea9503fd3437dd25 100644 (file)
@@ -73,8 +73,7 @@ public class TestHTTP extends PingTest {
 
         TestMail mail = getMailReciever().recieve();
         if (emailVariant == 0) {
-            String link = mail.extractLink();
-            new URL(link).openConnection().getHeaderField("");
+            mail.verify();
         }
         waitForPings(2);
 
@@ -106,7 +105,7 @@ public class TestHTTP extends PingTest {
         String httpDom = getTestProps().getProperty("domain.http");
         assumeNotNull(httpDom);
         URL u = new URL("http://" + httpDom + "/cacert-" + token + ".txt");
-        return IOUtils.readURL(new InputStreamReader(u.openStream())).trim();
+        return IOUtils.readURL(new InputStreamReader(u.openStream(), "UTF-8")).trim();
 
     }
 }