//compile with -lrt

//compile with -lrt

for

for ( int i = 0 ; i < 10 ; i ++ ) {

// size of shared memory object

// size of shared memory object

// pointer to shared memory object

// pointer to shared memory object

if

if ( ( fd = shm_open ( SHMOBJ_PATH , O_RDWR | O_CREAT | O_TRUNC , 0666 ) ) < 0 ) {