Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gmsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Larry Price
gmsh
Commits
b95d4510
Commit
b95d4510
authored
22 years ago
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
Fix crash due to identical vertex pointers in Mesh.Points and Mesh.Vertices
parent
d0439581
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
Mesh/Generator.cpp
+33
-44
33 additions, 44 deletions
Mesh/Generator.cpp
Mesh/Read_Mesh.cpp
+6
-2
6 additions, 2 deletions
Mesh/Read_Mesh.cpp
doc/VERSIONS
+3
-2
3 additions, 2 deletions
doc/VERSIONS
with
42 additions
and
48 deletions
Mesh/Generator.cpp
+
33
−
44
View file @
b95d4510
// $Id: Generator.cpp,v 1.
39
2003-03-
01 22:36:4
2 geuzaine Exp $
// $Id: Generator.cpp,v 1.
40
2003-03-
10 04:26:3
2 geuzaine Exp $
//
//
// Copyright (C) 1997 - 2003 C. Geuzaine, J.-F. Remacle
// Copyright (C) 1997 - 2003 C. Geuzaine, J.-F. Remacle
//
//
...
@@ -185,49 +185,38 @@ void Init_Mesh(Mesh * M, int all)
...
@@ -185,49 +185,38 @@ void Init_Mesh(Mesh * M, int all)
ExitExtrude
();
ExitExtrude
();
if
(
M
->
Vertices
)
{
Tree_Action
(
M
->
Vertices
,
Free_Vertex
);
Tree_Action
(
M
->
Vertices
,
Free_Vertex
);
Tree_Delete
(
M
->
Vertices
);
Tree_Delete
(
M
->
Vertices
);
}
Tree_Action
(
M
->
VertexEdges
,
Free_Vertex
);
if
(
M
->
VertexEdges
)
{
Tree_Delete
(
M
->
VertexEdges
);
Tree_Action
(
M
->
VertexEdges
,
Free_Vertex
);
Tree_Delete
(
M
->
VertexEdges
);
Tree_Action
(
M
->
Points
,
Free_Vertex
);
}
Tree_Delete
(
M
->
Points
);
if
(
M
->
Simplexes
)
{
// Tree_Action (M->Simplexes, Free_Simplex); //produit des crashes innatendus...
// Note: don't free the simplices here (with
// normal, cette memoire est dupliquee
// Tree_Action (M->Simplexes, Free_Simplex)): we free them
// dans les volumes. Je crois qu'on a besoin
// in each curve, surface, volume
// des 2, ce truc ne provoque pas de leaks.
Tree_Delete
(
M
->
Simplexes
);
Tree_Delete
(
M
->
Simplexes
);
}
Tree_Action
(
M
->
Curves
,
Free_Curve
);
if
(
M
->
Points
)
{
Tree_Delete
(
M
->
Curves
);
Tree_Action
(
M
->
Points
,
Free_Vertex
);
Tree_Delete
(
M
->
Points
);
//Tree_Action (M->SurfaceLoops, Free_SurfaceLoop); // todo
}
Tree_Delete
(
M
->
SurfaceLoops
);
if
(
M
->
Curves
)
{
Tree_Action
(
M
->
Curves
,
Free_Curve
);
//Tree_Action (M->EdgeLoops, Free_EdgeLoop); // todo
Tree_Delete
(
M
->
Curves
);
Tree_Delete
(
M
->
EdgeLoops
);
}
if
(
M
->
SurfaceLoops
)
{
Tree_Action
(
M
->
Surfaces
,
Free_Surface
);
//Tree_Action (M->SurfaceLoops, Free_SurfaceLoop);
Tree_Delete
(
M
->
Surfaces
);
Tree_Delete
(
M
->
SurfaceLoops
);
}
Tree_Action
(
M
->
Volumes
,
Free_Volume
);
if
(
M
->
EdgeLoops
)
{
Tree_Delete
(
M
->
Volumes
);
//Tree_Action (M->EdgeLoops, Free_EdgeLoop);
Tree_Delete
(
M
->
EdgeLoops
);
//Tree_Action (M->PhysicalGroups, Free_PhysicalGroup); // todo
}
List_Delete
(
M
->
PhysicalGroups
);
if
(
M
->
Surfaces
)
{
Tree_Action
(
M
->
Surfaces
,
Free_Surface
);
Tree_Delete
(
M
->
Surfaces
);
}
if
(
M
->
Volumes
)
{
Tree_Action
(
M
->
Volumes
,
Free_Volume
);
//produit des crashes innatendus...
Tree_Delete
(
M
->
Volumes
);
}
if
(
M
->
PhysicalGroups
)
{
//Tree_Action (M->PhysicalGroups, Free_PhysicalGroup);
List_Delete
(
M
->
PhysicalGroups
);
}
if
(
M
->
Metric
)
{
if
(
M
->
Metric
)
{
delete
M
->
Metric
;
delete
M
->
Metric
;
}
}
...
...
This diff is collapsed.
Click to expand it.
Mesh/Read_Mesh.cpp
+
6
−
2
View file @
b95d4510
// $Id: Read_Mesh.cpp,v 1.5
0
2003-03-
01 22:3
6:
4
2 geuzaine Exp $
// $Id: Read_Mesh.cpp,v 1.5
1
2003-03-
10 04:2
6:
3
2 geuzaine Exp $
//
//
// Copyright (C) 1997 - 2003 C. Geuzaine, J.-F. Remacle
// Copyright (C) 1997 - 2003 C. Geuzaine, J.-F. Remacle
//
//
...
@@ -316,7 +316,11 @@ void Read_Mesh_MSH(Mesh * M, FILE * File_GEO)
...
@@ -316,7 +316,11 @@ void Read_Mesh_MSH(Mesh * M, FILE * File_GEO)
M
->
Statistics
[
12
]
++
;
M
->
Statistics
[
12
]
++
;
break
;
break
;
case
PNT
:
case
PNT
:
Tree_Replace
(
M
->
Points
,
&
vertsp
[
0
]);
// we need to make a new one: vertices in M->Vertices and
// M->Points should never point to the same memory location
vert
=
Create_Vertex
(
vertsp
[
0
]
->
Num
,
vertsp
[
0
]
->
Pos
.
X
,
vertsp
[
0
]
->
Pos
.
Y
,
vertsp
[
0
]
->
Pos
.
Z
,
vertsp
[
0
]
->
lc
,
vertsp
[
0
]
->
w
);
Tree_Replace
(
M
->
Points
,
&
vert
);
break
;
break
;
default
:
default
:
Msg
(
WARNING
,
"Unknown type of element in Read_Mesh"
);
Msg
(
WARNING
,
"Unknown type of element in Read_Mesh"
);
...
...
This diff is collapsed.
Click to expand it.
doc/VERSIONS
+
3
−
2
View file @
b95d4510
$Id: VERSIONS,v 1.13
3
2003-03-
07 18:35:56
geuzaine Exp $
$Id: VERSIONS,v 1.13
4
2003-03-
10 04:26:32
geuzaine Exp $
New in 1.42: suppressed the automatic addition of a ".geo" extension
New in 1.42: suppressed the automatic addition of a ".geo" extension
if the file given on the command line is not recognized;
if the file given on the command line is not recognized; fixed various
small bugs;
New in 1.41: Gmsh is now licensed under the GNU General Public
New in 1.41: Gmsh is now licensed under the GNU General Public
License; general code cleanup (indent);
License; general code cleanup (indent);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment