Commit d487ad76 authored by Pavel Emelyanov's avatar Pavel Emelyanov

proc: Fix aio mapping detection

This is fixlet to patch #2.
Signed-off-by: 's avatarPavel Emelyanov <xemul@parallels.com>
Looks-good-to-me: Andrew Vagin <avagin@virtuozzo.com>
parent dde2adbc
......@@ -245,7 +245,7 @@ static int vma_get_mapfile(char *fname, struct vma_area *vma, DIR *mfd,
return 0;
}
if ((buf.st_mode & S_IFMT) == 0 && !strcmp(fname, AIO_FNAME)) {
if ((buf.st_mode & S_IFMT) == 0 && !strncmp(fname, AIO_FNAME, sizeof(AIO_FNAME) - 1)) {
/* AIO ring, let's try */
close(vma->vm_file_fd);
vma->aio_nr_req = -1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment