mirror of
https://github.com/taglib/taglib.git
synced 2025-07-18 21:14:23 -04:00
Merge remote-tracking branch 'TsudaKageyu/cross-border-delete'
This commit is contained in:
@ -194,10 +194,10 @@ void ID3v1::Tag::setTrack(uint i)
|
||||
|
||||
void ID3v1::Tag::setStringHandler(const StringHandler *handler)
|
||||
{
|
||||
if(TagPrivate::stringHandler != &defaultStringHandler)
|
||||
delete TagPrivate::stringHandler;
|
||||
|
||||
TagPrivate::stringHandler = handler;
|
||||
if (handler)
|
||||
TagPrivate::stringHandler = handler;
|
||||
else
|
||||
TagPrivate::stringHandler = &defaultStringHandler;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
@ -154,6 +154,11 @@ namespace TagLib {
|
||||
/*!
|
||||
* Sets the string handler that decides how the ID3v1 data will be
|
||||
* converted to and from binary data.
|
||||
* If the parameter \a handler is null, the previous handler is
|
||||
* released and default ISO-8859-1 handler is restored.
|
||||
*
|
||||
* \note The caller is responsible for deleting the previous handler
|
||||
* as needed after it is released.
|
||||
*
|
||||
* \see StringHandler
|
||||
*/
|
||||
|
Reference in New Issue
Block a user