Skip to content

Commit

Permalink
Fixed character encoding issue in #971
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanvs committed Jul 17, 2014
1 parent c697357 commit 76fad08
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/net/bytten/xkcdviewer/XkcdComicProvider.java
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@ public IComicInfo fetchComicInfo(Uri url) throws Exception {
Log.d("json", obj.names().toString());
XkcdComicInfo data = new XkcdComicInfo();
data.img = Uri.parse(obj.getString("img"));
data.alt = obj.getString("alt");
byte [] encodedAlt = obj.getString("alt").getBytes("ISO-8859-1");
data.alt = new String(encodedAlt, "UTF-8");
data.num = obj.getInt("num");
data.title = obj.getString("title");
if (obj.has("link") && obj.getString("link").length() > 0) {
Expand Down

0 comments on commit 76fad08

Please sign in to comment.