Skip to content

Commit 96d8ccf

Browse files
committed
Fixed a possible null pointer issue
1 parent 403cd0c commit 96d8ccf

File tree

1 file changed

+4
-1
lines changed
  • FFmpegAndroid/src/main/java/com/github/hiteshsondhi88/libffmpeg

1 file changed

+4
-1
lines changed

FFmpegAndroid/src/main/java/com/github/hiteshsondhi88/libffmpeg/FFmpeg.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,10 @@ public String getLibraryFFmpegVersion() {
120120

121121
@Override
122122
public boolean isFFmpegCommandRunning() {
123-
return ffmpegExecuteAsyncTask != null || !ffmpegExecuteAsyncTask.isProcessCompleted();
123+
if (ffmpegExecuteAsyncTask == null)
124+
return false;
125+
else
126+
return !ffmpegExecuteAsyncTask.isProcessCompleted();
124127
}
125128

126129
@Override

0 commit comments

Comments
 (0)