From 5f4a9ec55bd4bebfab62fa3c1c62461321b5467b Mon Sep 17 00:00:00 2001 From: Anthony Iliopoulos Date: Mon, 22 Aug 2022 13:02:49 +0200 Subject: winwidget: do not add an inotify watch if file is a url inotify_add_watch calls fail when the file is a url, since it does not correspond to an actual on-disk path. The temporary file path fetched by curl could be kept and monitored, but since this is unlikely to change just avoid monitoring files opened via a url. --- src/winwidget.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/winwidget.c b/src/winwidget.c index 9f61ba6..132b57e 100644 --- a/src/winwidget.c +++ b/src/winwidget.c @@ -739,7 +739,7 @@ void winwidget_inotify_remove(winwidget winwid) #ifdef HAVE_INOTIFY void winwidget_inotify_add(winwidget winwid, feh_file * file) { - if (opt.auto_reload) { + if (opt.auto_reload && !path_is_url(file->filename)) { D(("Adding inotify watch for %s\n", file->filename)); char dir[PATH_MAX]; feh_file_dirname(dir, file, PATH_MAX); -- cgit v1.2.3