remove

delete a file

Synopsis:

#include <stdio.h>
int remove( const char *filename );

Description:

The remove() function deletes the file whose name is the string pointed to by filename.

Returns:

The remove() function returns zero if the operation succeeds, non-zero if it fails. When an error has occurred, errno contains a value that indicates the type of error that has been detected.

See also:

errno

Examples:

#include <stdio.h>

void main()
  {
    remove( "vm.tmp" );
  }

Classification:

ANSI

Systems:

All (except DOS/PM)