diff options
| author | Magnus Lundborg <lundborg.magnus@gmail.com> | 2013-11-29 09:01:45 (GMT) | 
|---|---|---|
| committer | Magnus Lundborg <lundborg.magnus@gmail.com> | 2013-11-29 09:01:45 (GMT) | 
| commit | 96d51aeb702182abcc5e5d0b48f956b5c3d8e78e (patch) | |
| tree | 966e57297410e10f7c7ef92796ffb8e8d5cf23ef /src/lib | |
| parent | c9e1e813b4fb59bcc451c977758de64a5b9628b1 (diff) | |
Proper float comparison in tng_time_per_frame_set()
Diffstat (limited to 'src/lib')
| -rw-r--r-- | src/lib/tng_io.c | 2 | 
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/tng_io.c b/src/lib/tng_io.c index 5c5dd0f..f798b7c 100644 --- a/src/lib/tng_io.c +++ b/src/lib/tng_io.c @@ -10061,7 +10061,7 @@ tng_function_status DECLSPECDLLEXPORT tng_time_per_frame_set      TNG_ASSERT(tng_data, "TNG library: Trajectory container not properly setup.");      TNG_ASSERT(time >= 0, "TNG library: The time per frame must be >= 0."); -    if(time == tng_data->time_per_frame) +    if(fabs(time - tng_data->time_per_frame) < 0.00001)      {          return(TNG_SUCCESS);      }  | 
