Show detailed error message if writing tags fails
This commit is contained in:
1
NEWS
1
NEWS
@@ -9,6 +9,7 @@ ncmpcpp-0.8 (????-??-??)
|
||||
* The list of lyrics fetchers can now be set via configuration file.
|
||||
* Lyrics can now be fetched for songs with no tags.
|
||||
* libcurl dependency is no longer optional.
|
||||
* When an attempt to write tags fails, show detailed error message.
|
||||
|
||||
ncmpcpp-0.7.7 (2016-10-31)
|
||||
* Fixed compilation on 32bit platforms.
|
||||
|
||||
@@ -1392,8 +1392,8 @@ void EditLibraryTag::run()
|
||||
if (!Tags::write(ms))
|
||||
{
|
||||
success = false;
|
||||
const char msg[] = "Error while updating tags in \"%1%\"";
|
||||
Statusbar::printf(msg, wideShorten(ms.getURI(), COLS-const_strlen(msg)));
|
||||
Statusbar::printf("Error while writing tags to \"%1%\": %2%",
|
||||
ms.getName(), strerror(errno));
|
||||
s.finish();
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -806,8 +806,8 @@ void TagEditor::runAction()
|
||||
Statusbar::printf("Writing tags in \"%1%\"...", (*it)->getName());
|
||||
if (!Tags::write(**it))
|
||||
{
|
||||
const char msg[] = "Error while writing tags in \"%1%\"";
|
||||
Statusbar::printf(msg, wideShorten((*it)->getURI(), COLS-const_strlen(msg)).c_str());
|
||||
Statusbar::printf("Error while writing tags to \"%1%\": %2%",
|
||||
(*it)->getName(), strerror(errno));
|
||||
success = 0;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -172,7 +172,7 @@ void TinyTagEditor::runAction()
|
||||
}
|
||||
}
|
||||
else
|
||||
Statusbar::print("Error while writing tags");
|
||||
Statusbar::printf("Error while writing tags: %1%", strerror(errno));
|
||||
}
|
||||
if (option > 21)
|
||||
m_previous_screen->switchTo();
|
||||
|
||||
Reference in New Issue
Block a user