Errno. H --
Query
Checking the error code errno is an important way to debug the program. When the linuc c api function is abnormal, The errno variable (including
Errno. h) assign an integer. Different values indicate different meanings. You can
The errno definition in Linux. In the header file # include
124 emediumtype wrong medium type
123 enomedium no medium found
122 edquot Disk Quota exceeded
121 eremoteio remote I/O Error
120 eisnam is a named type file
119 enavail no XENIX
Note for fopen and note for fopen
Organized from https://msdn.microsoft.com/zh-cn/library/t3ayayh1 (VS.80). aspxErrno, _ doserrno, _ sys_errlist, and _ sys_nerr
These global variables include the error code used by the perror and strerror
124 emediumtype wrong medium type
123 enomedium no medium found
122 edquot Disk Quota exceeded
121 eremoteio remote I/O Error
120 eisnam is a named type file
119 enavail no XENIX semaphores available
118 enotnam not a xenix named type file
117
You can use the perror command in shell to display the perror function in the corresponding program API.
I = 1; while [$ I-Le 152]; DO perror $ I; let I = I + 1; done;
My kernel is defined as 152 only, as shown in the following table:
OS error
fopen (Open file)Correlation function Open,fclose
Table header file #include
Defines the function FILE * fopen (const char * path,const char * mode);
The function description parameter path string contains the file path and filename to open, and
What kind of network protocol does 1.nginx use?
Nginx is the application layer I think from the bottom up, the transport layer uses the TCP/IP application layer for HTTP
FastCGI is responsible for the scheduling process
2. ? echo ' Hello
Linux and other UNIX-like systems always come with a large number of tools that execute a wide range of functions from obvious to incredible. The success of a UNIX-like programming environment is largely attributed to the high quality and selection
In order to conveniently view the error code and its meaning in Linux, a program is written to print the information.
Listerrno. c
# Include # include # include # define MAX_ERRNO 256 int main (int argc, char * argv []) { int n = 0;
Program a creates child processes and invokes process B, depending on the different cases that are not called, and the results are displayed differently.#include #include#include#include#includeintMain () {pid_t pid, rpid; intStat; if(PID = fork ())
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.