This commit adds support to modify the vorbis comments of a flac
file. As usual, only the artist, title, album, year and comment tags
are supported.
As for the implementation, we first locate the vorbis comment
block by iterating over all metadata blocks. In this block
we replace each comment by the tags provided as an argument to
flac_rewrite_tags(). To work around a bug in old flac versions we
avoid to call FLAC__metadata_object_vorbiscomment_replace_comment(),
which would not replace tags as advertised. Instead we first delete
the comment and then append a new tag.
Once all tags have been replaced this way, we write out the temporary
file using FLAC__metadata_chain_write_with_callbacks_and_tempfile().
To do this we needed to convince libflac to not modify the original
file in place, which turned out to be more difficult than it should be.