return NULL on failure here
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Fri, 2 Mar 2012 03:04:33 +0000 (03:04 +0000)
committerMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Fri, 2 Mar 2012 03:04:33 +0000 (03:04 +0000)
SVN revision: 68613

legacy/eio/src/lib/eio_monitor.c

index 9d78dac..cca093c 100644 (file)
@@ -204,6 +204,11 @@ eio_monitor_stringshared_add(const char *path)
                                          _eio_monitor_stat_cb,
                                          _eio_monitor_error_cb,
                                          monitor);
+   if (!monitor->exist)
+     {
+        _eio_monitor_free(monitor);
+        return NULL;
+     }
 
    eina_hash_direct_add(_eio_monitors, path, monitor);