diff --git a/src/opus.cc b/src/opus.cc index 3a498fc..9d0315d 100644 --- a/src/opus.cc +++ b/src/opus.cc @@ -124,13 +124,3 @@ void ot::delete_tags(opus_tags *tags, const char *field) tags->comments.erase(current); } } - -/** - * \todo Return void. - */ -int ot::add_tags(opus_tags *tags, const char **tags_to_add, uint32_t count) -{ - for (uint32_t i = 0; i < count; ++i) - tags->comments.emplace_back(tags_to_add[i]); - return 0; -} diff --git a/src/opustags.cc b/src/opustags.cc index dccff47..3ca5bb4 100644 --- a/src/opustags.cc +++ b/src/opustags.cc @@ -304,10 +304,12 @@ int main(int argc, char **argv){ caught_eq = 1; field_len++; } - ot::add_tags(&tags, (const char**) raw_comment, raw_count); + for (size_t i = 0; i < raw_count; ++i) + tags.comments.emplace_back(raw_comment[i]); } } - ot::add_tags(&tags, to_add, count_add); + for (size_t i = 0; i < count_add; ++i) + tags.comments.emplace_back(to_add[i]); if(out){ ogg_packet packet; ot::render_tags(&tags, &packet); diff --git a/src/opustags.h b/src/opustags.h index ee3f3fa..ced1791 100644 --- a/src/opustags.h +++ b/src/opustags.h @@ -86,7 +86,6 @@ struct opus_tags { int parse_tags(const char *data, long len, opus_tags *tags); int render_tags(opus_tags *tags, ogg_packet *op); void delete_tags(opus_tags *tags, const char *field); -int add_tags(opus_tags *tags, const char **tags_to_add, uint32_t count); /** \} */