diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-08-15 21:54:06 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-08-15 21:54:06 +0000 |
commit | 5746309cb4be2073d550ad7a6885e918631dbc38 (patch) | |
tree | 89455bc4aadf977816b38df13f990372cd81d71a /src/util/time.c | |
parent | 6fd3e715cae09fa6e657c96f1c6f9711ee51f42f (diff) | |
download | gnunet-5746309cb4be2073d550ad7a6885e918631dbc38.tar.gz gnunet-5746309cb4be2073d550ad7a6885e918631dbc38.zip |
indentation
Diffstat (limited to 'src/util/time.c')
-rw-r--r-- | src/util/time.c | 29 |
1 files changed, 12 insertions, 17 deletions
diff --git a/src/util/time.c b/src/util/time.c index f4d4c4070..34880b08b 100644 --- a/src/util/time.c +++ b/src/util/time.c | |||
@@ -145,9 +145,8 @@ GNUNET_TIME_relative_to_absolute (struct GNUNET_TIME_Relative rel) | |||
145 | * @return timestamp that is smaller | 145 | * @return timestamp that is smaller |
146 | */ | 146 | */ |
147 | struct GNUNET_TIME_Relative | 147 | struct GNUNET_TIME_Relative |
148 | GNUNET_TIME_relative_min (struct | 148 | GNUNET_TIME_relative_min (struct GNUNET_TIME_Relative t1, |
149 | GNUNET_TIME_Relative | 149 | struct GNUNET_TIME_Relative t2) |
150 | t1, struct GNUNET_TIME_Relative t2) | ||
151 | { | 150 | { |
152 | return (t1.rel_value < t2.rel_value) ? t1 : t2; | 151 | return (t1.rel_value < t2.rel_value) ? t1 : t2; |
153 | } | 152 | } |
@@ -161,9 +160,8 @@ GNUNET_TIME_relative_min (struct | |||
161 | * @return timestamp that is larger | 160 | * @return timestamp that is larger |
162 | */ | 161 | */ |
163 | struct GNUNET_TIME_Relative | 162 | struct GNUNET_TIME_Relative |
164 | GNUNET_TIME_relative_max (struct | 163 | GNUNET_TIME_relative_max (struct GNUNET_TIME_Relative t1, |
165 | GNUNET_TIME_Relative | 164 | struct GNUNET_TIME_Relative t2) |
166 | t1, struct GNUNET_TIME_Relative t2) | ||
167 | { | 165 | { |
168 | return (t1.rel_value > t2.rel_value) ? t1 : t2; | 166 | return (t1.rel_value > t2.rel_value) ? t1 : t2; |
169 | } | 167 | } |
@@ -178,9 +176,8 @@ GNUNET_TIME_relative_max (struct | |||
178 | * @return timestamp that is smaller | 176 | * @return timestamp that is smaller |
179 | */ | 177 | */ |
180 | struct GNUNET_TIME_Absolute | 178 | struct GNUNET_TIME_Absolute |
181 | GNUNET_TIME_absolute_min (struct | 179 | GNUNET_TIME_absolute_min (struct GNUNET_TIME_Absolute t1, |
182 | GNUNET_TIME_Absolute | 180 | struct GNUNET_TIME_Absolute t2) |
183 | t1, struct GNUNET_TIME_Absolute t2) | ||
184 | { | 181 | { |
185 | return (t1.abs_value < t2.abs_value) ? t1 : t2; | 182 | return (t1.abs_value < t2.abs_value) ? t1 : t2; |
186 | } | 183 | } |
@@ -194,9 +191,8 @@ GNUNET_TIME_absolute_min (struct | |||
194 | * @return timestamp that is smaller | 191 | * @return timestamp that is smaller |
195 | */ | 192 | */ |
196 | struct GNUNET_TIME_Absolute | 193 | struct GNUNET_TIME_Absolute |
197 | GNUNET_TIME_absolute_max (struct | 194 | GNUNET_TIME_absolute_max (struct GNUNET_TIME_Absolute t1, |
198 | GNUNET_TIME_Absolute | 195 | struct GNUNET_TIME_Absolute t2) |
199 | t1, struct GNUNET_TIME_Absolute t2) | ||
200 | { | 196 | { |
201 | return (t1.abs_value > t2.abs_value) ? t1 : t2; | 197 | return (t1.abs_value > t2.abs_value) ? t1 : t2; |
202 | } | 198 | } |
@@ -298,9 +294,8 @@ GNUNET_TIME_absolute_add (struct GNUNET_TIME_Absolute start, | |||
298 | * @return ZERO if start <= duration, or FOREVER if start time is FOREVER; start-duration otherwise | 294 | * @return ZERO if start <= duration, or FOREVER if start time is FOREVER; start-duration otherwise |
299 | */ | 295 | */ |
300 | struct GNUNET_TIME_Absolute | 296 | struct GNUNET_TIME_Absolute |
301 | GNUNET_TIME_absolute_subtract (struct | 297 | GNUNET_TIME_absolute_subtract (struct GNUNET_TIME_Absolute start, |
302 | GNUNET_TIME_Absolute | 298 | struct GNUNET_TIME_Relative duration) |
303 | start, struct GNUNET_TIME_Relative duration) | ||
304 | { | 299 | { |
305 | struct GNUNET_TIME_Absolute ret; | 300 | struct GNUNET_TIME_Absolute ret; |
306 | 301 | ||
@@ -368,8 +363,8 @@ GNUNET_TIME_relative_divide (struct GNUNET_TIME_Relative rel, | |||
368 | * assuming it continues at the same speed | 363 | * assuming it continues at the same speed |
369 | */ | 364 | */ |
370 | struct GNUNET_TIME_Relative | 365 | struct GNUNET_TIME_Relative |
371 | GNUNET_TIME_calculate_eta (struct GNUNET_TIME_Absolute start, | 366 | GNUNET_TIME_calculate_eta (struct GNUNET_TIME_Absolute start, uint64_t finished, |
372 | uint64_t finished, uint64_t total) | 367 | uint64_t total) |
373 | { | 368 | { |
374 | struct GNUNET_TIME_Relative dur; | 369 | struct GNUNET_TIME_Relative dur; |
375 | double exp; | 370 | double exp; |