1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-10-26 00:03:52 +02:00

Comment where xml writing functions may throw

This commit is contained in:
Paul Licameli
2016-12-01 17:03:40 -05:00
parent e3355c3c7e
commit b81cdee7e3
26 changed files with 44 additions and 2 deletions

View File

@@ -1026,6 +1026,7 @@ XMLTagHandler *Sequence::HandleXMLChild(const wxChar *tag)
// Throws exceptions rather than reporting errors.
void Sequence::WriteXML(XMLWriter &xmlFile) const
// may throw
{
unsigned int b;
@@ -1544,8 +1545,9 @@ bool Sequence::Append(samplePtr buffer, sampleFormat format,
blockFileLog != NULL),
lastBlock.start
);
// FIXME: TRAP_ERR This could throw an exception that should(?) be converted to return false.
if (blockFileLog)
// shouldn't throw, because XMLWriter is not XMLFileWriter
static_cast< SimpleBlockFile * >( &*newLastBlock.f )
->SaveXML( *blockFileLog );
@@ -1570,8 +1572,8 @@ bool Sequence::Append(samplePtr buffer, sampleFormat format,
blockFileLog != NULL);
}
// FIXME: TRAP_ERR This could throw an exception that should(?) be converted to return false.
if (blockFileLog)
// shouldn't throw, because XMLWriter is not XMLFileWriter
static_cast< SimpleBlockFile * >( &*pFile )->SaveXML( *blockFileLog );
mBlock.push_back(SeqBlock(pFile, mNumSamples));