Updated Branches:
  refs/heads/master 81f283e56 -> e51b4897a

Guard against null mimeType in MediaFile.getFormatData


Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/repo
Commit: 
http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/commit/e51b4897
Tree: 
http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/tree/e51b4897
Diff: 
http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/diff/e51b4897

Branch: refs/heads/master
Commit: e51b4897a34c8d4430ad8036cff86f7fd95747b8
Parents: 81f283e
Author: Simon MacDonald <[email protected]>
Authored: Thu Nov 8 14:01:46 2012 -0500
Committer: Simon MacDonald <[email protected]>
Committed: Thu Nov 8 14:01:46 2012 -0500

----------------------------------------------------------------------
 framework/src/org/apache/cordova/Capture.java |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cordova-android/blob/e51b4897/framework/src/org/apache/cordova/Capture.java
----------------------------------------------------------------------
diff --git a/framework/src/org/apache/cordova/Capture.java 
b/framework/src/org/apache/cordova/Capture.java
index 4cf46dd..3eecf37 100644
--- a/framework/src/org/apache/cordova/Capture.java
+++ b/framework/src/org/apache/cordova/Capture.java
@@ -127,7 +127,7 @@ public class Capture extends CordovaPlugin {
 
         // If the mimeType isn't set the rest will fail
         // so let's see if we can determine it.
-        if (mimeType == null || mimeType.equals("")) {
+        if (mimeType == null || mimeType.equals("") || 
"null".equals(mimeType)) {
             mimeType = FileUtils.getMimeType(filePath);
         }
         Log.d(LOG_TAG, "Mime type = " + mimeType);

Reply via email to