summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2019-09-01 13:58:45 +0200
committerMax Kellermann <max@musicpd.org>2020-09-16 20:40:06 +0200
commita8e23c414047064048a0cabfe0c94f772fdaea57 (patch)
treeb6d37f130ab993172e042176c54308ed68f44625
parentfc3861b4217e0ee76ecaa64ddaaed22c936c78cc (diff)
db/update/InotifySource: add `noexcept`
-rw-r--r--src/db/update/InotifySource.cxx2
-rw-r--r--src/db/update/InotifySource.hxx4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/db/update/InotifySource.cxx b/src/db/update/InotifySource.cxx
index ac3c931ff..e8b61e874 100644
--- a/src/db/update/InotifySource.cxx
+++ b/src/db/update/InotifySource.cxx
@@ -98,7 +98,7 @@ InotifySource::Add(const char *path_fs, unsigned mask)
}
void
-InotifySource::Remove(unsigned wd)
+InotifySource::Remove(unsigned wd) noexcept
{
auto ifd = GetSocket().ToFileDescriptor();
int ret = inotify_rm_watch(ifd.Get(), wd);
diff --git a/src/db/update/InotifySource.hxx b/src/db/update/InotifySource.hxx
index 43225df56..846d44682 100644
--- a/src/db/update/InotifySource.hxx
+++ b/src/db/update/InotifySource.hxx
@@ -42,7 +42,7 @@ public:
InotifySource(EventLoop &_loop,
mpd_inotify_callback_t callback, void *ctx);
- ~InotifySource() {
+ ~InotifySource() noexcept {
Close();
}
@@ -60,7 +60,7 @@ public:
*
* @param wd the watch descriptor returned by mpd_inotify_source_add()
*/
- void Remove(unsigned wd);
+ void Remove(unsigned wd) noexcept;
private:
bool OnSocketReady(unsigned flags) noexcept override;