aboutsummaryrefslogtreecommitdiffstats
path: root/src/input/plugins
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2014-10-02 20:16:05 +0200
committerMax Kellermann <max@duempel.org>2014-10-02 20:16:05 +0200
commit2f02e49b9f353d8c0e75711308f88e98e1a6a97c (patch)
tree36bfa7f9f984b202976e488f151d70fdf7e1b602 /src/input/plugins
parent064e8a7c6803c9607e9336ea8756e65a0bb24289 (diff)
downloadmpd-2f02e49b9f353d8c0e75711308f88e98e1a6a97c.tar.gz
mpd-2f02e49b9f353d8c0e75711308f88e98e1a6a97c.tar.xz
mpd-2f02e49b9f353d8c0e75711308f88e98e1a6a97c.zip
input/file: generate Error when errno==ENOENT
This special case was useless. Fixes the dreaded "Unrecognized URI" error message when a file does not exist.
Diffstat (limited to 'src/input/plugins')
-rw-r--r--src/input/plugins/FileInputPlugin.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/input/plugins/FileInputPlugin.cxx b/src/input/plugins/FileInputPlugin.cxx
index a4c809915..e12439cd3 100644
--- a/src/input/plugins/FileInputPlugin.cxx
+++ b/src/input/plugins/FileInputPlugin.cxx
@@ -70,7 +70,7 @@ input_file_open(const char *filename,
const int fd = open_cloexec(filename, O_RDONLY|O_BINARY, 0);
if (fd < 0) {
- if (errno != ENOENT && errno != ENOTDIR)
+ if (errno != ENOTDIR)
error.FormatErrno("Failed to open \"%s\"",
filename);
return nullptr;