what is the difference between exit() and _exit() functions?

Answers were Sorted based on User's Feedback



what is the difference between exit() and _exit() functions?..

Answer / vin

The exit() and _exit() both are the same except that the
exit() perform flushing of I/O buffer before terminating
while _exit() does not perform.

Is This Answer Correct ?    6 Yes 1 No

what is the difference between exit() and _exit() functions?..

Answer / bajishareef

exit() perform the termination operation, but before that it closes all files and flushes the I/O buffers.
_exit() just terminates the program

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More C Interview Questions

What are types of preprocessor in c?

0 Answers  


How can I sort a linked list?

0 Answers  


Where are local variables stored in c?

0 Answers  


Does c have class?

0 Answers  


What is page thrashing?

0 Answers  






Can a variable be both static and volatile in c?

0 Answers  


Binary tree traversing

1 Answers   Qualcomm,


What are the different file extensions involved when programming in C?

0 Answers  


What are the general description for loop statement and available loop types in c?

0 Answers  


What is #include in c?

0 Answers  


52.write a “Hello World” program in “c” without using a semicolon? 53.Give a method to count the number of ones in a 32 bit number? 54.write a program that print itself even if the source file is deleted? 55.Given an unsigned integer, find if the number is power of 2?

9 Answers  


Evaluate the following: int fn(int v) { if(v==1 || v==0) return 1; if(v%2==0) return fn(v/2)+2; else return fn(v-1)+3; } for fn(7); 1) 10 2) 11 3) 1

6 Answers  


Categories