Rev 5472 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 5472 | Rev 5483 | ||
---|---|---|---|
Line 232... | Line 232... | ||
232 | absolute_path[strrchr(#absolute_path, '/')] = '\0'; |
232 | absolute_path[strrchr(#absolute_path, '/')] = '\0'; |
233 | strcat(#absolute_path, relative_path); |
233 | strcat(#absolute_path, relative_path); |
234 | } |
234 | } |
235 | return #absolute_path; |
235 | return #absolute_path; |
236 | } |
236 | } |
- | 237 | ||
- | 238 | :dword ConvertSize(unsigned int bytes) |
|
- | 239 | { |
|
- | 240 | unsigned char size_prefix[8], size_nm[4]; |
|
- | 241 | if (bytes>=1073741824) strcpy(#size_nm, " Gb"); |
|
- | 242 | else if (bytes>=1048576) strcpy(#size_nm, " Mb"); |
|
- | 243 | else if (bytes>=1024) strcpy(#size_nm, " Kb"); |
|
- | 244 | else strcpy(#size_nm, " b "); |
|
- | 245 | while (bytes>1023) bytes/=1024; |
|
- | 246 | itoa_(#size_prefix, bytes); |
|
- | 247 | strcat(#size_prefix, #size_nm); |
|
- | 248 | return #size_prefix; |
|
- | 249 | } |
|
237 | 250 |