set NONBLOCK on /proc/self/mountinfo file descriptor

SVN revision: 74738
This commit is contained in:
Mike Blumenkrantz 2012-08-01 13:32:38 +00:00
parent f782172e5a
commit d890c977ff
1 changed files with 2 additions and 0 deletions

View File

@ -434,6 +434,8 @@ eeze_mount_tabs_watch(void)
_mountinfo = open("/proc/self/mountinfo", O_RDONLY, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH);
if (_mountinfo < 0) goto error;
if (fcntl(_mountinfo, F_SETFL, O_NONBLOCK) < 0) goto error;
_mountinfo_fdh = ecore_main_fd_handler_add(_mountinfo, ECORE_FD_ERROR, _eeze_mount_fdh, NULL, NULL, NULL);
if (!_mountinfo_fdh) goto error;
_fstab_mon = ecore_file_monitor_add("/etc/fstab", _eeze_mount_tab_watcher, NULL);