Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
SWIFTsim
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
70
Issues
70
List
Boards
Labels
Milestones
Merge Requests
14
Merge Requests
14
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
SWIFT
SWIFTsim
Commits
7cb536a4
Commit
7cb536a4
authored
Apr 18, 2018
by
Peter W. Draper
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use sparts bound not parts bound
parent
e73f5dc0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
src/space.c
src/space.c
+2
-2
No files found.
src/space.c
View file @
7cb536a4
...
...
@@ -654,7 +654,7 @@ void space_rebuild(struct space *s, int verbose) {
if
(
cells_top
[
sind
[
k
]].
nodeID
!=
local_nodeID
)
{
nr_sparts
-=
1
;
/* Swap the particle */
memswap
(
&
s
->
sparts
[
k
],
&
s
->
sparts
[
nr_parts
],
sizeof
(
struct
spart
));
memswap
(
&
s
->
sparts
[
k
],
&
s
->
sparts
[
nr_
s
parts
],
sizeof
(
struct
spart
));
/* Swap the link with the gpart */
if
(
s
->
sparts
[
k
].
gpart
!=
NULL
)
{
s
->
sparts
[
k
].
gpart
->
id_or_neg_offset
=
-
k
;
...
...
@@ -663,7 +663,7 @@ void space_rebuild(struct space *s, int verbose) {
s
->
sparts
[
nr_sparts
].
gpart
->
id_or_neg_offset
=
-
nr_sparts
;
}
/* Swap the index */
memswap
(
&
sind
[
k
],
&
sind
[
nr_parts
],
sizeof
(
int
));
memswap
(
&
sind
[
k
],
&
sind
[
nr_
s
parts
],
sizeof
(
int
));
}
else
{
/* Increment when not exchanging otherwise we need to retest "k".*/
k
++
;
...
...
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