diff --git a/src/zm_videostore.cpp b/src/zm_videostore.cpp index a5375d526..c1f966de7 100644 --- a/src/zm_videostore.cpp +++ b/src/zm_videostore.cpp @@ -404,9 +404,11 @@ Debug(2, "Have audio_output_context"); } } // end if is AAC +if ( audio_output_stream ) { if (oc->oformat->flags & AVFMT_GLOBALHEADER) { audio_output_context->flags |= CODEC_FLAG_GLOBAL_HEADER; } + } } else { Debug(3, "No Audio output stream"); @@ -668,7 +670,7 @@ int VideoStore::writeAudioFramePacket( AVPacket *ipkt ) { Debug(4, "writeAudioFrame"); if(!audio_output_stream) { - Error("Called writeAudioFramePacket when no audio_output_stream"); + Debug(1, "Called writeAudioFramePacket when no audio_output_stream"); return 0;//FIXME -ve return codes do not free packet in ffmpeg_camera at the moment } /*if(!keyframeMessage)