aboutsummaryrefslogtreecommitdiff
path: root/sdn.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'sdn.cpp')
-rw-r--r--sdn.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/sdn.cpp b/sdn.cpp
index a7aa16a..9e9a5ab 100644
--- a/sdn.cpp
+++ b/sdn.cpp
@@ -1738,7 +1738,7 @@ fun watch_check () {
while ((len = read (g.watch_fd, buf, sizeof buf)) > 0) {
const inotify_event *e;
for (char *ptr = buf; ptr < buf + len; ptr += sizeof *e + e->len) {
- e = (const inotify_event *) buf;
+ e = (const inotify_event *) ptr;
if (e->wd == g.watch_wd)
changed = true;
}