aio_qphysio(): Avoid uninitialized pointer read on error.

For the !unmap case it may happen that pbuf gets called unreferenced
when vm_fault_quick_hold_pages() fails.
Initialize it so it doesn't cause trouble.

CID:		1352776
Reviewed by:	jhb
MFC after:	1 week
This commit is contained in:
pfg 2016-03-18 19:04:01 +00:00
parent 47415357ac
commit eea894a1e2

View File

@ -1226,7 +1226,8 @@ aio_qphysio(struct proc *p, struct kaiocb *job)
if (!unmap) {
job->pbuf = pbuf = (struct buf *)getpbuf(NULL);
BUF_KERNPROC(pbuf);
}
} else
pbuf = NULL;
AIO_LOCK(ki);
if (!unmap)