changeset 7217:9fa2f8dcb869

inotify: friendlier message when daemon not running
author Matt Mackall <mpm@selenic.com>
date Wed, 22 Oct 2008 17:41:41 -0500
parents 292fb2ad2846
children 1bd7f90465b3
files hgext/inotify/__init__.py
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/inotify/__init__.py	Wed Oct 22 17:34:52 2008 -0500
+++ b/hgext/inotify/__init__.py	Wed Oct 22 17:41:41 2008 -0500
@@ -85,6 +85,8 @@
                         except socket.error, err:
                             ui.warn(_('could not talk to new inotify '
                                            'server: %s\n') % err[-1])
+                elif err[0] == errno.ENOENT:
+                    ui.warn(_('(inotify server not running)\n'))
                 else:
                     ui.warn(_('failed to contact inotify server: %s\n')
                              % err[-1])