Commit 02d5cb81 by Andrew Lewis

Use Build.DEVICE not Build.PRODUCT.

On HTC Butterfly these match, but Build.DEVICE is actually the right value to
use.

Issue: #377
parent cb1e6ad4
......@@ -178,8 +178,8 @@ public class MediaCodecUtil {
// Workaround an issue where creating a particular MP3 decoder on some HTC devices on platform
// API version 16 crashes mediaserver.
if (Util.SDK_INT == 16
&& ("dlxu".equals(Util.PRODUCT) // HTC Butterfly
|| "protou".equals(Util.PRODUCT)) // HTC Desire X
&& ("dlxu".equals(Util.DEVICE) // HTC Butterfly
|| "protou".equals(Util.DEVICE)) // HTC Desire X
&& name.equals("OMX.qcom.audio.decoder.mp3")) {
return false;
}
......
......@@ -62,10 +62,10 @@ public final class Util {
public static final int SDK_INT = android.os.Build.VERSION.SDK_INT;
/**
* Like {@link android.os.Build#PRODUCT}, but in a place where it can be conveniently overridden
* Like {@link android.os.Build#DEVICE}, but in a place where it can be conveniently overridden
* for local testing.
*/
public static final String PRODUCT = android.os.Build.PRODUCT;
public static final String DEVICE = android.os.Build.DEVICE;
private static final Pattern XS_DATE_TIME_PATTERN = Pattern.compile(
"(\\d\\d\\d\\d)\\-(\\d\\d)\\-(\\d\\d)[Tt]"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment