[TIMOB-6523] Android: Titanium.Media.Sound - V8/Rhino - Android 2.x - player crashes on play or repeated play
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Low |
Status | Closed |
Resolution | Invalid |
Resolution Date | 2017-06-07T22:42:48.000+0000 |
Affected Version/s | Release 1.7.5, Release 1.8.0.1 |
Fix Version/s | n/a |
Components | Android |
Labels | n/a |
Reporter | Dustin Hyde |
Assignee | Ingo Muschenetz |
Created | 2011-12-08T17:32:21.000+0000 |
Updated | 2017-06-07T22:42:48.000+0000 |
Description
Titanium.Media.Sound using V8/Rhino crashes on play or repeated play. This occurs in 1.7.5 and 1.8.0.1. The crashes occur in 2.x (occurs after less clicks in V8). Android 3.x/4.0 haven't crashed, but in 3.x the app locked-up. There were instances of 2.x losing sound capabilities (in the app) without a crash, but with similar logs. None of this occurs in iOS. Crash log attached.
Steps to Reproduce:
1. Run the following code in a new app (sound file attached).
var playCounter = 0;
var win = Titanium.UI.createWindow({
backgroundColor:'#fff',
orientationModes:[Ti.UI.LANDSCAPE_RIGHT]
});
var button = Ti.UI.createButton({
title:'click'
});
button.addEventListener('click', Playsound);
win.add(button);
win.open();
function Playsound(){
playCounter++;
Ti.API.info("Playing sound, nr: " + playCounter);
var player =Ti.Media.createSound({
url: "cat.mp3"
});
player.addEventListener('complete', function(e) {
player.release();
player = null;
Ti.API.info("Sound played correctly");
});
player.play();
}
2. Press the 'click' button repeatedly (a dozen times).
Expected Result:
The sounds should play.
Actual Result:
The app crashes, sometimes on the first click. Alternately, the click button will no longer play sounds, or no longer register click events.
Attachments
File | Date | Size |
---|---|---|
android sound crash.txt | 2011-12-08T17:32:21.000+0000 | 7530 |
cat.mp3 | 2011-12-08T17:32:21.000+0000 | 23822 |
Closing ticket due to the time passed and lack of progress.