Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: src/org/adblockplus/sbrowser/contentblocker/engine/Downloader.java

Issue 29372653: Issue 4813 - UTFDataFormatException while serializing filter (Closed)
Patch Set: Including UTF-8 constant and adding migration/file corruption recovery logic Created March 9, 2017, 7:38 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/org/adblockplus/sbrowser/contentblocker/engine/Engine.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/org/adblockplus/sbrowser/contentblocker/engine/Downloader.java
===================================================================
--- a/src/org/adblockplus/sbrowser/contentblocker/engine/Downloader.java
+++ b/src/org/adblockplus/sbrowser/contentblocker/engine/Downloader.java
@@ -97,17 +97,17 @@ final class Downloader
break;
}
final String value = connection.getHeaderField(i);
job.responseHeaders.put(key.toLowerCase(), value);
}
final StringBuilder sb = new StringBuilder();
final BufferedReader r = new BufferedReader(new InputStreamReader(connection.getInputStream(),
- "UTF-8"));
+ Engine.CHARSET_UTF_8));
try
{
for (int ch = r.read(); ch != -1; ch = r.read())
{
sb.append((char) ch);
}
job.responseText = sb.toString();
}
« no previous file with comments | « no previous file | src/org/adblockplus/sbrowser/contentblocker/engine/Engine.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld