diff -r 2d3e1993fb02 -r c7e61a0077eb camcordermmfplugin/mediarecorder/Src/CCMRMediaRecorderImp.cpp --- a/camcordermmfplugin/mediarecorder/Src/CCMRMediaRecorderImp.cpp Tue Jan 26 12:06:59 2010 +0200 +++ b/camcordermmfplugin/mediarecorder/Src/CCMRMediaRecorderImp.cpp Tue Feb 02 00:20:52 2010 +0200 @@ -399,7 +399,10 @@ // this can't be changed while recording; video recorder is supposed to notice if in wrong state // state is changed based on mvroStateChange() iVideoRecorder->SetFrameSizeL(aSize); - iConfig->SetVideoFrameSize(aSize); + if ( iConfig != NULL ) + { + iConfig->SetVideoFrameSize(aSize); + } // Change audio samplerate based on framesize TSize framesize; @@ -494,12 +497,15 @@ { TInt abr; // check that the total bit-rate (audio+video) does not exceed a given limit - iAudioRecorder->TargetBitRateL(abr); - if ( iAudioRecorder && iAudioEnabled && ( abr > 0 ) && - ( abr + aBitRate > iMaxTargetBitRate ) ) + if ( iAudioRecorder != NULL ) { - PRINT((_L("CCMRMediaRecorderImp::SetVideoBitRateL() too high combined bitrate"))); - User::Leave(KErrArgument); + iAudioRecorder->TargetBitRateL(abr); + if ( iAudioEnabled && ( abr > 0 ) && + ( abr + aBitRate > iMaxTargetBitRate ) ) + { + PRINT((_L("CCMRMediaRecorderImp::SetVideoBitRateL() too high combined bitrate"))); + User::Leave(KErrArgument); + } } }