The problem is that cb_stateSaveFE() overflows an iovec array
on its stack. When it returns, the PC is loaded with garbage and the
process crashes.
(cherry picked from commit
edaa34d3a0ea74bffd886ec40e1c13af7c38a4af)
goto done;
}
cbdsk[idx].index = cbi;
- iov[idx].iov_base = (char *)&cbdsk[idx];
- len += iov[idx].iov_len = sizeof(struct CBDiskEntry);
+ iov[iovcnt].iov_base = (char *)&cbdsk[idx];
+ len += iov[iovcnt].iov_len = sizeof(struct CBDiskEntry);
iovcnt++;
if ((iovcnt == 16) || (!cb->cnext)) {
if (fs_stateWriteV(state, iov, iovcnt)) {