Lines Matching defs:length
41 * Read the metadata block length, this is stored in the first two
45 u64 *cur_index, int *offset, int *length)
55 *length = (unsigned char) bh->b_data[*offset];
60 *length |= (unsigned char) bh->b_data[0] << 8;
63 *length = (unsigned char) bh->b_data[*offset] |
83 * filesystem), otherwise the length is obtained from the first two bytes of
84 * the metadata block. A bit in the length field indicates if the block
89 int length, u64 *next_index, int srclength, int pages)
102 if (length) {
107 compressed = SQUASHFS_COMPRESSED_BLOCK(length);
108 length = SQUASHFS_COMPRESSED_SIZE_BLOCK(length);
110 *next_index = index + length;
113 index, compressed ? "" : "un", length, srclength);
115 if (length < 0 || length > srclength ||
116 (index + length) > msblk->bytes_used)
119 for (b = 0; bytes < length; b++, cur_index++) {
133 bh[0] = get_block_length(sb, &cur_index, &offset, &length);
139 compressed = SQUASHFS_COMPRESSED(length);
140 length = SQUASHFS_COMPRESSED_SIZE(length);
142 *next_index = index + length + 2;
145 compressed ? "" : "un", length);
147 if (length < 0 || length > srclength ||
148 (index + length) > msblk->bytes_used)
151 for (; bytes < length; b++) {
161 length = squashfs_decompress(msblk, buffer, bh, b, offset,
162 length, srclength, pages);
163 if (length < 0)
177 for (bytes = length; k < b; k++) {
199 return length;