Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tsoc
openmm
Commits
ad8c2627
Commit
ad8c2627
authored
Feb 02, 2016
by
peastman
Browse files
Fixed a rare segfault in CPU platform
parent
14cdc9ae
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
platforms/cpu/src/CpuNeighborList.cpp
platforms/cpu/src/CpuNeighborList.cpp
+3
-3
No files found.
platforms/cpu/src/CpuNeighborList.cpp
View file @
ad8c2627
...
...
@@ -6,7 +6,7 @@
* Biological Structures at Stanford, funded under the NIH Roadmap for *
* Medical Research, grant U54 GM072970. See https://simtk.org. *
* *
* Portions copyright (c) 2013-201
5
Stanford University and the Authors. *
* Portions copyright (c) 2013-201
6
Stanford University and the Authors. *
* Authors: Peter Eastman *
* Contributors: *
* *
...
...
@@ -158,8 +158,8 @@ public:
float
scale1
=
floorf
(
yperiodic
*
recipBoxSize
[
1
]);
yperiodic
-=
periodicBoxVectors
[
1
][
0
]
*
scale1
;
}
int
y
=
min
(
ny
-
1
,
int
(
floorf
(
yperiodic
/
voxelSizeY
)));
int
z
=
min
(
nz
-
1
,
int
(
floorf
(
zperiodic
/
voxelSizeZ
)));
int
y
=
max
(
0
,
min
(
ny
-
1
,
int
(
floorf
(
yperiodic
/
voxelSizeY
)))
)
;
int
z
=
max
(
0
,
min
(
nz
-
1
,
int
(
floorf
(
zperiodic
/
voxelSizeZ
)))
)
;
return
VoxelIndex
(
y
,
z
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment