test: Update shared mem test

Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
This commit is contained in:
Cyrill Gorcunov 2011-11-14 17:17:38 +04:00
parent 6a26e75aba
commit c9c2bddcb8

View file

@ -38,14 +38,16 @@ int main(int argc, char *argv[])
}
if (pid == 0) {
int cnt = 0;
while(1) {
printf("%d: shmem '%s'\n", getpid(), (char *)map);
sprintf(map, "shared-mem-%d", cnt++);
sleep(5);
}
} else {
while(1) {
printf("%d: shmem '%s'\n", getpid(), (char *)map);
sleep(5);
sleep(3);
}
}