Linux application Development-system function mode file programming

Source: Internet
Author: User

Linux Application Development-system function mode file programming a system call


Refers to the function library that invokes the system


Two-file descriptor


Nature: A number


The open file corresponds to a number that is a file descriptor


Three common functions


1 Open File


Open


2 Creating a File


creat


3 Closing files


Close


4 Read File


Read


5 Writing Files


Write


6 Locating files


Lseek


7 Copying file descriptors


Dup


Three man command lookup order
1 Command man Read


2 system Call function Man 2 read


3 Library functions


Four Linux under Main function parameters


void Main (int arge, char **argv)


Arge is the number of command-line arguments, argv is the parameter


ARGV[0] for the command name ARGV[1] bit first parameter argv[2] for the second argument


Column such as CP 1.c 2.c arge = 3 Argv[0] = CP argv[1] = "1.c" argv[2] = "2.c"

Linux application Development-system function mode file programming

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.