diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/tests/tng_io_read_pos.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/tests/tng_io_read_pos.c b/src/tests/tng_io_read_pos.c index edd85ae..753f475 100644 --- a/src/tests/tng_io_read_pos.c +++ b/src/tests/tng_io_read_pos.c @@ -54,11 +54,7 @@ int main(int argc, char **argv) // N.B. No proper error checks. if(tng_particle_data_interval_get(traj, TNG_TRAJ_POSITIONS, first_frame, last_frame, TNG_USE_HASH, &positions, &n_particles, &n_values_per_frame, - &data_type) != TNG_SUCCESS) - { - printf("Cannot read positions\n"); - } - else + &data_type) == TNG_SUCCESS) { // Print the positions of the wanted particle (zero based) for(i=0; i<n_frames; i++) @@ -84,6 +80,10 @@ int main(int argc, char **argv) } } } + else + { + printf("Cannot read positions\n"); + } // Free memory if(positions) |