Skip to content

Commit

Permalink
Fixed an issue that caused an app crash if the processing of the vide…
Browse files Browse the repository at this point in the history
…o was cancelled right after it started. This caused the assetWriter of the GPUImageMovieWriter to be in an unknown state instead of a cancelled state.
  • Loading branch information
Fco Javier Valdera committed May 29, 2013
1 parent 82c8bfc commit 845df55
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion framework/Source/iOS/GPUImageMovieWriter.m
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,8 @@ - (void)finishRecording;

- (void)finishRecordingWithCompletionHandler:(void (^)(void))handler;
{
if (assetWriter.status == AVAssetWriterStatusCompleted || assetWriter.status == AVAssetWriterStatusCancelled)
if (assetWriter.status == AVAssetWriterStatusCompleted || assetWriter.status == AVAssetWriterStatusCancelled
|| assetWriter.status == AVAssetWriterStatusUnknown)
{
return;
}
Expand Down

0 comments on commit 845df55

Please sign in to comment.