The endpwent function closes the user database and any private stream used by getpwent. No value is returned. If an I/O error occurred, the function sets errno to EIO. See also getpwent, getpwuid, getpwnam, and setpwent.