Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
stored: fix memory corruption in label.cc
pointer lifetime in WriteNewVolumeLabelToDev() Previously, in WriteNewVolumeLabelToDev() a copy of the pointer dcr->block was saved and then used as a parameter to EmptyBlock(). This pointer's lifetime ends in dev->SetLabelBlockSize() when the previously written device's block size was larger than the label block size. This patch removes the copy and uses dcr->block directly, so the updated pointer is used.
- Loading branch information