diff -r 8a14024f954a -r cfe32394fcd5 stif/TestInterface/src/TestModuleIf.cpp --- a/stif/TestInterface/src/TestModuleIf.cpp Mon Mar 15 12:46:13 2010 +0200 +++ b/stif/TestInterface/src/TestModuleIf.cpp Thu Apr 01 00:00:49 2010 +0300 @@ -279,6 +279,13 @@ VA_LIST list; VA_START(list,aFmt); TName aBuf; + RBuf buf; + TInt ret = buf.Create(1024); + if(ret != KErrNone) + { + __RDEBUG((_L("STF: Printf: Buffer creation failed [%d]"), ret)); + return; + } // Cut the description length TInt len = aDefinition.Length(); @@ -293,9 +300,17 @@ TDesOverflowHandler overFlowHandler (this, aPriority, shortDescription); // Parse parameters - aBuf.AppendFormatList(aFmt,list, &overFlowHandler); + buf.AppendFormatList(aFmt, list, &overFlowHandler); + + if(buf.Length() == 0) + { + __RDEBUG((_L("STF: Printf: Unable to prepare print buffer (probably printed string is too long)"))); + } // Print + aBuf.Copy(buf.Left(aBuf.MaxLength())); + buf.Close(); + iTestExecution->DoNotifyPrint( aPriority, shortDescription, aBuf ); }