Skip to content
Snippets Groups Projects
Commit afa6e86c authored by deuce's avatar deuce
Browse files

Added test for multiple concurrent locks.

parent f799023a
No related branches found
No related tags found
No related merge requests found
...@@ -111,6 +111,10 @@ int main() ...@@ -111,6 +111,10 @@ int main()
printf("Locks in first thread survive open()/close() in other thread\n"); printf("Locks in first thread survive open()/close() in other thread\n");
else else
printf("!FAILURE lock() in first thread lost by open()/close() in other thread\n"); printf("!FAILURE lock() in first thread lost by open()/close() in other thread\n");
if(lock(fd,LOCK_OFFSET+LOCK_LEN+1,LOCK_LEN))
printf("!FAILURE file locking\n");
else
printf("SUCCESS! Record locking\n");
close(fd); close(fd);
/* getch test */ /* getch test */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment