mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-21 07:31:26 +02:00
Fix potential memory leak in src/Format.cpp
(Merging pull request #233)
This commit is contained in:
@@ -213,7 +213,7 @@ std::vector<char> format::VideoBufferToPPM(const VideoBuffer & vidBuf)
|
|||||||
}
|
}
|
||||||
data.insert(data.end(), currentRow, currentRow+(vidBuf.Width*3));
|
data.insert(data.end(), currentRow, currentRow+(vidBuf.Width*3));
|
||||||
}
|
}
|
||||||
delete currentRow;
|
delete [] currentRow;
|
||||||
|
|
||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user