]> git.ipfire.org Git - thirdparty/man-pages.git/blame - man2/inotify_rm_watch.2
sched_setattr.2: tfix
[thirdparty/man-pages.git] / man2 / inotify_rm_watch.2
CommitLineData
4d2b74dd
MK
1.\" Copyright (C) 2005 Robert Love
2.\"
1dd72f9c 3.\" %%%LICENSE_START(GPLv2+_DOC_FULL)
4d2b74dd
MK
4.\" This is free documentation; you can redistribute it and/or
5.\" modify it under the terms of the GNU General Public License as
6.\" published by the Free Software Foundation; either version 2 of
7.\" the License, or (at your option) any later version.
8.\"
9.\" The GNU General Public License's references to "object code"
10.\" and "executables" are to be interpreted as the output of any
11.\" document formatting or typesetting system, including
12.\" intermediate and printed output.
13.\"
14.\" This manual is distributed in the hope that it will be useful,
15.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
16.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17.\" GNU General Public License for more details.
18.\"
19.\" You should have received a copy of the GNU General Public
c715f741
MK
20.\" License along with this manual; if not, see
21.\" <http://www.gnu.org/licenses/>.
6a8d8745 22.\" %%%LICENSE_END
4d2b74dd
MK
23.\"
24.\" 2005-07-19 Robert Love <rlove@rlove.org> - initial version
25.\" 2006-02-07 mtk, minor changes
26.\"
4b8c67d9 27.TH INOTIFY_RM_WATCH 2 2017-09-15 "Linux" "Linux Programmer's Manual"
4d2b74dd
MK
28.SH NAME
29inotify_rm_watch \- remove an existing watch from an inotify instance
30.SH SYNOPSIS
6e969f22 31.B #include <sys/inotify.h>
68e4db0a 32.PP
01710c8d
MK
33.BI "int inotify_rm_watch(int " fd ", int " wd );
34.\" Before glibc 2.10, the second argument was types as uint32_t.
35.\" http://sources.redhat.com/bugzilla/show_bug.cgi?id=7040
4d2b74dd
MK
36.SH DESCRIPTION
37.BR inotify_rm_watch ()
38removes the watch associated with the watch descriptor
39.I wd
40from the inotify instance associated with the file descriptor
41.IR fd .
efeece04 42.PP
4d2b74dd
MK
43Removing a watch causes an
44.B IN_IGNORED
c13182ef
MK
45event to be generated for this watch descriptor.
46(See
4d2b74dd 47.BR inotify (7).)
47297adb 48.SH RETURN VALUE
4d2b74dd
MK
49On success,
50.BR inotify_rm_watch ()
b680b4c3
MK
51returns zero.
52On error, \-1 is returned and
4d2b74dd 53.I errno
b680b4c3 54is set to indicate the cause of the error.
4d2b74dd
MK
55.SH ERRORS
56.TP
57.B EBADF
a6183de0 58.I fd
4d2b74dd
MK
59is not a valid file descriptor.
60.TP
61.B EINVAL
62The watch descriptor
63.I wd
9f5774a9
MK
64is not valid; or
65.I fd
66is not an inotify file descriptor.
ff457ccb 67.SH VERSIONS
4d2b74dd 68Inotify was merged into the 2.6.13 Linux kernel.
47297adb 69.SH CONFORMING TO
8382f16d 70This system call is Linux-specific.
47297adb 71.SH SEE ALSO
c13182ef 72.BR inotify_add_watch (2),
f0c34053 73.BR inotify_init (2),
ccd2b351 74.BR inotify (7)