fd_close

fd_close — closes a file identified by a file descriptor.

Syntax

fd_close (fd)

		

Arguments

fd

A file descriptor as returned from fd_open.

Returns

t, if successful, otherwise nil.

Description

This function closes a file identifed by a file descriptor, ie. that was opened by fd_open.

Example

Gamma> require_lisp("const/filesys");
"const/filesys"
Gamma> fp = fd_open("/fd/ttyp8",O_WRONLY);
4
Gamma> fd_write(fp,"\nHello\n");
8
Gamma> fd_close(fp);
t
Gamma> fd_close(fp);	
nil
		

See Also

close, fd_open, Referencing Files