incorrect index in shared memory