1 #include <common.h> 2 3 int 4 main(void) { 5 sem_t id; 6 7 if (sem_init(&id, 0, 1) < 0) { 8 return 1; 9 } 10 11 if (sem_destroy(&id) < 0) { 12 perror("sem_destroy"); 13 return 1; 14 } 15 return 0; 16 } 17