Print this page
    
    
      
        | Split | 
	Close | 
      
      | Expand all | 
      | Collapse all | 
    
    
          --- old/usr/src/man/man3c/inotify_add_watch.3c.man.txt
          +++ new/usr/src/man/man3c/inotify_add_watch.3c.man.txt
   1    1  INOTIFY_ADD_WATCH(3C)    Standard C Library Functions    INOTIFY_ADD_WATCH(3C)
   2    2  
   3    3  
   4    4  
   5    5  NAME
   6    6         inotify_add_watch - add a watch to an inotify instance
   7    7  
   8    8  SYNOPSIS
   9    9         #include <sys/inotify.h>
  10   10  
  11   11         int inotify_add_watch(int fd, const char *pathname, uint32_t mask);
  12   12  
  13   13  
  14   14  DESCRIPTION
  15   15         The inotify_add_watch() function adds a watch for the file or directory
  16   16         specified by pathname to the inotify instance specified by fd for the
  17   17         events specified by mask.  See inotify(5) for details on the meaning of
  18   18         mask, how it affects the interpretation of pathname, and how events for
  19   19         the watched file or directory are subsequently retrieved via read(2).
  20   20  
  21   21  
  22   22  RETURN VALUES
  23   23         Upon succesful completion, inotify_add_watch() returns the watch
  24   24         descriptor associated with the new watch.  If an error occurs, -1 is
  25   25         returned and errno is set to indicate the error.
  26   26  
  27   27  
  28   28  ERRORS
  29   29         inotify_add_watch() will fail if:
  30   30  
  31   31         EACCES
  32   32                   pathname could not be opened for reading.
  33   33  
  34   34  
  35   35         EBADF
  36   36                   The fd argument is not a valid open file descriptor.
  37   37  
  38   38  
  39   39         EFAULT
  40   40                   The memory associated with pathname was not mapped.
  41   41  
  42   42  
  43   43         EINVAL
  44   44                   The fd argument does not correspond to an inotify(5) instance
  45   45                   as initialized with inotify_init(3C) or inotify_init1(3C).
  46   46  
  47   47  
  48   48         ENOSPC
  49   49                   The number of watches on the specified instance would exceed
  50   50                   the maximum number of watches per inotify(5) instance.
  51   51  
  52   52  
  53   53         ENOTDIR
  54   54                   pathname does not correspond to a directory and IN_ONLYDIR
  55   55                   was specified in mask.
  56   56  
  57   57  
  58   58  
  59   59  NOTES
  60   60         While the inotify(5) facility is implemented for purposes of offering
  61   61         compatibility for Linux-borne applications, native applications may opt
  62   62         to use it instead of (or in addition to) the PORT_SOURCE_FILE
  63   63         capability of event ports.  See inotify(5) for details and
  64   64         restrictions.
  65   65  
  66   66  
  67   67  SEE ALSO
  68   68         inotify_init(3C), inotify_init1(3C), port_create(3C),
  69   69         port_associate(3C), port_get(3C), inotify(5)
  70   70  
  71   71  
  72   72  
  73   73                                September 17, 2014         INOTIFY_ADD_WATCH(3C)
  
    | 
      ↓ open down ↓ | 
    73 lines elided | 
    
      ↑ open up ↑ | 
  
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX