Comments (3)
I am also getting same error:
free(): invalid pointer
Aborted (core dumped)
on building from the terminal in Ubuntu 18.04
What should I do?
from 3denginecpp.
Hello, I know that this is old repo, but I also have the same issue like shivamprasad99 with free(): invalid pointer
Aborted (core dumped). Maybe someone resolve this issue already?
from 3denginecpp.
Fixes to prevent Policy warnings from syntax errors in CMake code files.
- File: ./cmake/FindGLEW.cmake
insert: SET(PROGRAMFILESX86 "PROGRAMFILES(X86)")
before: SET( GLEW_SEARCH_PATHS
and
change: "$ENV{PROGRAMFILES(X86)}/GLEW" # WINDOWS
to: "$ENV{${PROGRAMFILESX86}}/GLEW" # WINDOWS
- File: ./cmake/FindSDL2.cmake
insert: SET(PROGRAMFILESX86 "PROGRAMFILES(X86)")
before: SET( SDL2_SEARCH_PATHS
and
change: "$ENV{PROGRAMFILES(X86)}/SDL2" # WINDOWS
to: "$ENV{${PROGRAMFILESX86}}/SDL2" # WINDOWS
- File: ./cmake/FindASSIMP.cmake
insert: SET(PROGRAMFILESX86 "PROGRAMFILES(X86)")
before: SET( ASSIMP_SEARCH_PATHS
and
change: "$ENV{PROGRAMFILES(X86)}/ASSIMP" # WINDOWS
to: "$ENV{${PROGRAMFILESX86}}/ASSIMP" # WINDOWS
Fixes to prevent program execution abort on free(): invalid pointer.
- File: ./src/rendering/texture.h, line 60
from: void operator=(Texture texture);
to: Texture& operator=(Texture other) noexcept;
-
File: ./src/rendering/texture.cpp, lines 207-213
replace:
void Texture::operator=(Texture texture)
{
char* temp[sizeof(Texture)/sizeof(char)];
memcpy(temp, this, sizeof(Texture));
memcpy(this, &texture, sizeof(Texture));
memcpy(&texture, temp, sizeof(Texture));
}
with:
Texture& Texture::operator=(Texture other) noexcept
{
//Implemented using move assignment.
//Guard self assignment
if (this == &other)
return *this;
if(m_textureData && m_textureData->RemoveReference())
{
if(m_fileName.length() > 0)
s_resourceMap.erase(m_fileName);
delete m_textureData;
}
m_fileName = other.m_fileName;
m_textureData = other.m_textureData;
m_textureData->AddReference();
return *this;
}
from 3denginecpp.
Related Issues (20)
- Runtime failure HOT 5
- Deferred Rendering HOT 3
- Variance Shadow Mapping texture problem HOT 2
- Too high window sync time HOT 8
- Mesh load failed! HOT 2
- VSM issue
- Support for Multi-Mesh OBJ files HOT 1
- Plane IntersectSphere
- Can someone tell me what to do for a "unistd.h" not found? Issue on a windows machine. HOT 4
- Calculating shadow map coordinates from model space or world space position.
- Framebuffer with stencil HOT 1
- Matrix Inverse implementation HOT 4
- Smooth shading / vertex normals HOT 5
- animation
- Linux build [Ubuntu/Arch] Segfault HOT 3
- Plane normalization
- Light shaders render stuff after zFar plane
- Change 3DEngineCpp to 3DEngineC
- Fix to free(): invalid pointer: #45
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from 3denginecpp.