Match the following WINDOWS system calls with the equivalent UNIX system calls, with reference to process control and file manipulation:
Windows: (A) CreateProcess() (B) WaitForSingleObject() (C) CreateFile() (D) CloseHandle()
UNIX: (I) open() (II) close() (III) fork() (IV) wait()
Pick an option to check yourself, or open the answer below.
Show answer & explanation
Correct answer: A. A-III, B-IV, C-I, D-II
Explanation
CreateProcess() creates a new Windows process, the direct equivalent of UNIX's fork() (A-III). WaitForSingleObject() blocks the caller until a handle such as a child process signals completion, matching UNIX's wait() (B-IV). CreateFile() opens or creates a file handle in Windows, equivalent to UNIX's open() (C-I), and CloseHandle() releases a Windows handle just as close() releases a UNIX file descriptor (D-II). This gives A-III, B-IV, C-I, D-II, which is option (i).More Software Engineering questions
- Which statement is not correct about the 'init' process in UNIX?
- Which UNIX command correctly changes the case of only the first three lines of the file "shortlist" from lower case to upper case?
- Match the following basic vi editor commands in UNIX with their functions. List I (Command): (a) dd (b) yy (c) p (d) u List II (Function):…
- Consider the following statements about linker software: (I) A linker combines multiple object (relocatable) modules into a single load mod…
- A distributed operating system typically consists of:
- Which of the following statements about UNIX signals is NOT correct?