---
name: "rfio_close"
section: "3"
platform: "linux"
package: "libdpm-dev"
version: "1.10.0-2+b3"
release: "Debian 10 (Buster)"
platforms: ["linux"]
url: "https://new.carta.tech/rfio_close"
---

# rfio\_close(3)

closes a file

## NAME

rfio\_close - closes a file

## SYNOPSIS

**#include \<sys/types.h\>**\
 **#include "rfio\_api.h"**

**int rfio\_close (int** *s***);**

## DESCRIPTION

**rfio\_close** closes the file whose descriptor **s** is the one returned by **rfio\_open.**

## RETURN VALUE

This routine returns 0 if successful, -1 if the operation failed and **serrno** is set appropriately.

## ERRORS

- **EBADF**

  *s* is not a valid file descriptor.

- **ENOSPC**

  File system full when writing last blocks (V3 only).

- **SENOSHOST**

  Host unknown.

- **SENOSSERV**

  Service unknown.

- **SETIMEDOUT**

  Timed out.

- **SEBADVERSION**

  Version ID mismatch.

- **SEINTERNAL**

  Internal error.

- **SECONNDROP**

  Connection closed by remote end.

- **SECOMERR**

  Communication error.

## SEE ALSO

**[rfio\_open(3)](/rfio_open/3.md)**

## AUTHOR

**LCG Grid Deployment** Team
