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