- Timestamp:
- Jul 3, 2003, 10:46:22 PM (21 years ago)
- Branches:
- master, barnowl_perlaim, debian, owl, release-1.10, release-1.4, release-1.5, release-1.6, release-1.7, release-1.8, release-1.9
- Children:
- 9ceee9d
- Parents:
- de03334
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
util.c
rde03334 r5b85d19 281 281 282 282 /* caller must free the return */ 283 char *owl_util_ seconds_to_timestr(int seconds)283 char *owl_util_minutes_to_timestr(int in) 284 284 { 285 285 int days, minutes, hours; … … 287 287 char *out; 288 288 289 run=seconds; 290 291 days=run/86400; 292 run-=days*86400; 293 hours=run/3600; 294 run-=hours*3600; 295 minutes=run/60; 296 run-=minutes*60; 289 run=in; 290 291 days=run/1440; 292 run-=days*1440; 293 hours=run/60; 294 run-=hours*60; 297 295 298 296 if (days>0) { 299 out=owl_sprintf("%i d %2.2i:%2.2i :%2.2li", days, hours, minutes, run);297 out=owl_sprintf("%i d %2.2i:%2.2i", days, hours, run); 300 298 } else { 301 out=owl_sprintf(" %2.2i:%2.2i :%2.2li", hours, minutes, run);299 out=owl_sprintf(" %2.2i:%2.2i", hours, run); 302 300 } 303 301 return(out);
Note: See TracChangeset
for help on using the changeset viewer.