mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-15 22:02:49 -06:00
.examples Fix AndroidMath MemoryManger class
git-svn-id: svn://ultimatepp.org/upp/trunk@9573 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
d93859a302
commit
c0ccc87f10
7 changed files with 94 additions and 51 deletions
|
|
@ -22,10 +22,10 @@ Vector::Vector(int size)
|
|||
Vector::Vector(const Vector& vec)
|
||||
{
|
||||
if(vec.GetSize() > 0) {
|
||||
size = vec.GetSize();
|
||||
data = new float[size];
|
||||
this->size = vec.GetSize();
|
||||
this->data = new float[size];
|
||||
for(int i = 0; i < size; i++) {
|
||||
data[i] = vec.data[i];
|
||||
this->data[i] = vec.data[i];
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
|
@ -36,8 +36,7 @@ Vector::Vector(const Vector& vec)
|
|||
|
||||
Vector::~Vector()
|
||||
{
|
||||
if(data != NULL)
|
||||
delete[] data;
|
||||
//delete[] data;
|
||||
}
|
||||
|
||||
float Vector::Get(int id) const
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue