-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix 64-bit index bug found by compiler warning
- Loading branch information
1 parent
5e2692b
commit 7e7e643
Showing
2 changed files
with
55 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
diff --git a/fem/gridfunc.cpp b/fem/gridfunc.cpp | ||
index 310d8d704..bd5504d63 100644 | ||
--- a/fem/gridfunc.cpp | ||
+++ b/fem/gridfunc.cpp | ||
@@ -1924,9 +1924,9 @@ void GridFunction::GetNodalValues(Vector &nval, int vdim) const | ||
Array<double> values; | ||
Array<int> overlap(fes->GetNV()); | ||
nval.SetSize(fes->GetNV()); | ||
- | ||
nval = 0.0; | ||
overlap = 0; | ||
+ nval.HostReadWrite(); | ||
for (i = 0; i < fes->GetNE(); i++) | ||
{ | ||
fes->GetElementVertices(i, vertices); |