62 |
|
free( the_event ); |
63 |
|
} |
64 |
|
|
65 |
+ |
void init_cutoffgroup( int cutoffgroup_index ){ |
66 |
+ |
event* the_event; |
67 |
+ |
|
68 |
+ |
the_event = (event* )malloc( sizeof( event ) ); |
69 |
+ |
|
70 |
+ |
the_event->event_type = CUTOFFGROUP; |
71 |
+ |
the_event->err_msg = NULL; |
72 |
+ |
the_event->evt.blk_index = cutoffgroup_index; |
73 |
+ |
|
74 |
+ |
if( !event_handler( the_event ) ) interface_error( the_event ); |
75 |
+ |
#ifdef IS_MPI |
76 |
+ |
throwMPIEvent(the_event); |
77 |
+ |
#endif |
78 |
+ |
|
79 |
+ |
free( the_event ); |
80 |
+ |
} |
81 |
+ |
|
82 |
|
void init_atom( int atom_index ){ |
83 |
|
event* the_event; |
84 |
|
|
172 |
|
void init_members( struct node_tag* the_node, |
173 |
|
struct namespc the_namespc ){ |
174 |
|
event* the_event; |
175 |
+ |
int i; |
176 |
|
|
177 |
|
the_event = (event* )malloc( sizeof( event ) ); |
178 |
|
|
179 |
< |
the_event->event_type = MEMBER; |
179 |
> |
the_event->event_type = MEMBERS; |
180 |
|
the_event->err_msg = NULL; |
181 |
< |
the_event->evt.mbr.a = the_node->the_data.mbr.a; |
182 |
< |
the_event->evt.mbr.b = the_node->the_data.mbr.b; |
165 |
< |
the_event->evt.mbr.c = the_node->the_data.mbr.c; |
166 |
< |
the_event->evt.mbr.d = the_node->the_data.mbr.d; |
181 |
> |
|
182 |
> |
the_event->evt.mbrs.nMembers = the_node->the_data.mbrs.nMembers; |
183 |
|
|
184 |
+ |
the_event->evt.mbrs.memberList = (int *) calloc(the_node->the_data.mbrs.nMembers, |
185 |
+ |
sizeof(int)); |
186 |
+ |
|
187 |
+ |
for (i = 0; i < the_node->the_data.mbrs.nMembers; i++) { |
188 |
+ |
the_event->evt.mbrs.memberList[i] = the_node->the_data.mbrs.memberList[i]; |
189 |
+ |
} |
190 |
+ |
|
191 |
|
if( !event_handler( the_event ) ) interface_error( the_event ); |
192 |
|
#ifdef IS_MPI |
193 |
|
throwMPIEvent(the_event); |
194 |
|
#endif |
195 |
|
|
196 |
+ |
free( the_event->evt.mbrs.memberList ); |
197 |
|
free( the_event ); |
198 |
|
} |
199 |
|
|
280 |
|
|
281 |
|
the_event->event_type = ORIENTATION; |
282 |
|
the_event->err_msg = NULL; |
283 |
< |
the_event->evt.ornt.x = the_node->the_data.ort.x; |
284 |
< |
the_event->evt.ornt.y = the_node->the_data.ort.y; |
285 |
< |
the_event->evt.ornt.z = the_node->the_data.ort.z; |
283 |
> |
the_event->evt.ornt.phi = the_node->the_data.ort.phi; |
284 |
> |
the_event->evt.ornt.theta = the_node->the_data.ort.theta; |
285 |
> |
the_event->evt.ornt.psi = the_node->the_data.ort.psi; |
286 |
|
|
287 |
|
if( !event_handler( the_event ) ) interface_error( the_event ); |
288 |
|
#ifdef IS_MPI |