Changes in uspace/app/testread/testread.c [9d58539:1ab8539] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/app/testread/testread.c
r9d58539 r1ab8539 123 123 struct timeval prev_time; 124 124 struct timeval start_time; 125 int rc; 126 rc = gettimeofday(&start_time, NULL); 127 if (rc != EOK) { 128 printf("gettimeofday failed\n"); 129 fclose(file); 130 free(buf); 131 return 1; 132 } 125 gettimeofday(&start_time, NULL); 133 126 prev_time = start_time; 134 127 … … 155 148 if (progress && offset >= next_mark) { 156 149 struct timeval cur_time; 157 rc = gettimeofday(&cur_time, NULL); 158 if (rc != EOK) { 159 printf("gettimeofday failed\n"); 160 fclose(file); 161 free(buf); 162 return 1; 163 } 150 gettimeofday(&cur_time, NULL); 151 164 152 uint32_t last_run = cur_time.tv_sec - prev_time.tv_sec; 165 153 uint32_t total_time = cur_time.tv_sec - start_time.tv_sec; … … 178 166 179 167 struct timeval final_time; 180 rc = gettimeofday(&final_time, NULL); 181 if (rc != EOK) { 182 printf("gettimeofday failed\n"); 183 fclose(file); 184 free(buf); 185 return 1; 186 } 168 gettimeofday(&final_time, NULL); 187 169 188 170 uint32_t total_run_time = final_time.tv_sec - start_time.tv_sec;
Note:
See TracChangeset
for help on using the changeset viewer.