changeset 31:f5c5e6f4edc8 draft

handle GAMCreated on feeds for which a file descriptor was already open Signed-off-by: Changaco <changaco ατ changaco δοτ net>
author Changaco <changaco ατ changaco δοτ net>
date Sun, 05 Aug 2012 13:00:37 +0200
parents 7e935b48f53a
children 5348758c622d
files feed-push
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/feed-push
+++ b/feed-push
@@ -162,6 +162,9 @@ def handle_feed_change(path, event):
             handle_feed_change(path, gamin.GAMChanged)
         else:
             ignore_event(path, event)
+    elif event == gamin.GAMCreated:
+        path_to_feed_fd.pop(path).close()
+        handle_feed_change(path, gamin.GAMCreated)
     elif event == gamin.GAMChanged:
         feed_fd = path_to_feed_fd[path]
         feed_fd.seek(0)