Home  >  Article  >  Backend Development  >  What does remove mean?

What does remove mean?

藏色散人
藏色散人Original
2019-05-18 09:16:2414712browse

remove is a function in C language. Its general function is to delete all elements of arrays and linked list objects. The function prototype is [intremove (char*filename)].

What does remove mean?

Function function

remove() function is used to delete the specified file. Its prototype is as follows:

int remove(char *filename);

Function declaration 2:

template<classPath>inline bool remove(const Path &Pval);

Function parameters

filename is the name of the file to be deleted, which can be a directory. If the parameter filename is a file, call unlink() for processing; if the parameter filename is a directory, call rmdir() for processing.

Function return value

Returns 0 if successful, -1 if failed, and the error reason is stored in errno.

Function error code

● EROFS The file to be written is a read-only file.

● EFAULT parameter filename pointer exceeds the accessible memory space.

● ENAMETOOLONG parameter filename is too long.

● ENOMEM Insufficient core memory.

● The ELOOP parameter filename has too many symbolic connections.

● EIO I/O access error.

The above is the detailed content of What does remove mean?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn