1
0
mirror of https://gitlab.com/fdroid/fdroidserver.git synced 2024-10-03 17:50:11 +02:00

Fixed text corruption problem in marketcheck.

The problem was due to marketcheck using DataInputStream.readLine(),
which is a fundamentally broken function and has been deprecated since
Java 1.1. Strings in Java consist of Unicode characters, not bytes.
This commit is contained in:
Henrik Tunedal 2011-01-27 19:59:57 +01:00
parent 635555827d
commit 6fd360e62d
3 changed files with 8 additions and 8 deletions

View File

@ -61,15 +61,15 @@ class test {
App app = response.getAppList().get(0);
String filespec = "../metadata/" + app.getPackageName() + ".txt";
FileInputStream fi = new FileInputStream(filespec);
BufferedInputStream bi = new BufferedInputStream(fi);
DataInputStream di = new DataInputStream(bi);
InputStreamReader isr = new InputStreamReader(fi, "UTF-8");
BufferedReader br = new BufferedReader(isr);
StringBuilder output = new StringBuilder();
boolean changed = false;
boolean vercodefound = false;
boolean versionfound = false;
String line, newline;
while (di.available() != 0) {
line = di.readLine();
while (br.ready()) {
line = br.readLine();
if (line.startsWith("Market Version:")) {
versionfound = true;
newline="Market Version:" + app.getVersion();
@ -87,8 +87,8 @@ class test {
}
output.append(line + "\n");
}
di.close();
bi.close();
br.close();
isr.close();
fi.close();
if(!versionfound) {
changed = true;

View File

@ -6,7 +6,7 @@ Summary:Keyboard for Scandinavian languages
Description:
A modified version of the standard onscreen keyboard in Android
with support for Norwegian, Swedish, Danish, Faroese, German,
Icelandic and Northern Sámi keyboard layouts.
Icelandic and Northern Sámi keyboard layouts.
.
Repo Type:svn
Repo:http://scandinavian-keyboard.googlecode.com/svn/trunk

View File

@ -4,7 +4,7 @@ Source Code:http://github.com/fabrantes/rockonnggl
Issue Tracker:http://github.com/fabrantes/rockonnggl/issues
Summary:Music player
Description:
A music player. Cubed, also known as ³, has possibly the silliest choice of application
A music player. Cubed, also known as ³, has possibly the silliest choice of application
name ever.
.
Market Version:1.0.81