[ https://issues.apache.org/jira/browse/CB-4541?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Bas Bosman updated CB-4541: --------------------------- Component/s: Plugin Media Capture > MediaFile.getFormatData throws a MediaPlayer IOException but returns callback > success for a video > ------------------------------------------------------------------------------------------------- > > Key: CB-4541 > URL: https://issues.apache.org/jira/browse/CB-4541 > Project: Apache Cordova > Issue Type: Bug > Components: Android, Plugin Media Capture > Affects Versions: 2.9.0 > Environment: Galaxy GT-I9000 > Gingerbread 2.3.6 > Reporter: Angela Fowler > Assignee: Joe Bowser > Priority: Minor > > Here is the initial MediaFile success callback > "S01 Capture1970865120 > [{"lastModifiedDate":1375937605000,"fullPath":"file:\/\/\/mnt\/sdcard\/DCIM\/Camera\/video-2013-08-08-14-53-17.mp4","type":"video\/mp4","size":1824506,"name":"video-2013-08-08-14-53-17.mp4"}]" > Then try to get the format information about the media file using > mediaFile.getFormatData(getFormatDataWin, getFormatDataError); > In Capture.java getAudioVideoData an exception is thrown by > mediaplayer.prepare() > java.io.IOException: Prepare failed.: status=0xFFFFFFFC > The error is logged but ignored. > "Error: loading video file" > The Capture.java execute method calls success on the callback context. > Here is the getFormatData success callback message > "S01 Capture1970865121 > {"codecs":"","bitrate":0,"duration":0,"height":0,"width":0}" > Error callback is never returned for action "getFormatData". > Also what happens if another exception which is not caught is thrown? e.g. > IllegalStateException > It appears that no callback would be made in this case. -- This message was sent by Atlassian JIRA (v6.1.5#6160)