| <refentry id="func-close"> |
| <refentrytitle>V4L2 close()</refentrytitle> |
| <refname>v4l2-close</refname> |
| <refpurpose>Close a V4L2 device</refpurpose> |
| <funcsynopsisinfo>#include <unistd.h></funcsynopsisinfo> |
| <funcdef>int <function>close</function></funcdef> |
| <paramdef>int <parameter>fd</parameter></paramdef> |
| <term><parameter>fd</parameter></term> |
| <title>Description</title> |
| <para>Closes the device. Any I/O in progress is terminated and |
| resources associated with the file descriptor are freed. However data |
| format parameters, current input or output, control values or other |
| properties remain unchanged.</para> |
| <title>Return Value</title> |
| <para>The function returns <returnvalue>0</returnvalue> on |
| success, <returnvalue>-1</returnvalue> on failure and the |
| <varname>errno</varname> is set appropriately. Possible error |
| <term><errorcode>EBADF</errorcode></term> |
| <para><parameter>fd</parameter> is not a valid open file |
| sgml-parent-document: "v4l2.sgml" |