Commit 25bc06f9 authored by Christopher Tenter's avatar Christopher Tenter

avoid writing to invalid address with memcpy

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@20585 383ad7c9-94d9-4d36-a494-682f7c89f535
parent dc34b188
......@@ -123,11 +123,11 @@ public:
* movq $0x0,(%rsp)
*
*/
memcpy(this->mat_ + 0, col1.data(), sizeof(double) * 3);
memcpy(this->mat_ + 0, col1.data(), sizeof(Scalar) * 3);
this->mat_[3] = 0;
memcpy(this->mat_ + 4, col2.data(), sizeof(double) * 3);
memcpy(this->mat_ + 4, col2.data(), sizeof(Scalar) * 3);
this->mat_[7] = 0;
memcpy(this->mat_ + 8, col3.data(), sizeof(double) * 3);
memcpy(this->mat_ + 8, col3.data(), sizeof(Scalar) * 3);
for (int i = 11; i < 15; ++i) this->mat_[i] = 0;
this->mat_[15] = 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