Glenn L McGrath | 7ca04f3 | 2002-09-25 02:47:48 +0000 | [diff] [blame] | 1 | #include <errno.h> |
2 | #include <sys/types.h> | ||||
3 | #include <unistd.h> | ||||
4 | #include "unarchive.h" | ||||
5 | #include "libbb.h" | ||||
6 | |||||
7 | extern const unsigned short data_align(const int src_fd, const unsigned int offset, const unsigned short align_to) | ||||
8 | { | ||||
9 | const unsigned short skip_amount = (align_to - (offset % align_to)) % align_to; | ||||
10 | seek_sub_file(src_fd, skip_amount); | ||||
11 | |||||
12 | return(skip_amount); | ||||
13 | } |