Lines Matching refs:buffer

137 	uint32_t buffer[6];  in read_header()  local
139 memcpy(&buffer, *tzf, sizeof(buffer)); in read_header()
140 tz->bit32.ttisgmtcnt = timelib_conv_int_unsigned(buffer[0]); in read_header()
141 tz->bit32.ttisstdcnt = timelib_conv_int_unsigned(buffer[1]); in read_header()
142 tz->bit32.leapcnt = timelib_conv_int_unsigned(buffer[2]); in read_header()
143 tz->bit32.timecnt = timelib_conv_int_unsigned(buffer[3]); in read_header()
144 tz->bit32.typecnt = timelib_conv_int_unsigned(buffer[4]); in read_header()
145 tz->bit32.charcnt = timelib_conv_int_unsigned(buffer[5]); in read_header()
146 *tzf += sizeof(buffer); in read_header()
159 int32_t *buffer = NULL; in read_transitions() local
164 buffer = (int32_t*) timelib_malloc(tz->bit32.timecnt * sizeof(int32_t)); in read_transitions()
165 if (!buffer) { in read_transitions()
168 memcpy(buffer, *tzf, sizeof(int32_t) * tz->bit32.timecnt); in read_transitions()
171 buffer[i] = timelib_conv_int_signed(buffer[i]); in read_transitions()
173 if (i > 0 && !(buffer[i] > buffer[i - 1])) { in read_transitions()
180 timelib_free(buffer); in read_transitions()
187 tz->trans = buffer; in read_transitions()
210 unsigned char *buffer; in read_types() local
214 buffer = (unsigned char*) timelib_malloc(tz->bit32.typecnt * sizeof(unsigned char) * 6); in read_types()
215 if (!buffer) { in read_types()
218 memcpy(buffer, *tzf, sizeof(unsigned char) * 6 * tz->bit32.typecnt); in read_types()
223 timelib_free(buffer); in read_types()
230 …et += (int32_t) (((uint32_t) buffer[j]) << 24) + (buffer[j + 1] << 16) + (buffer[j + 2] << 8) + tz… in read_types()
231 tz->type[i].isdst = buffer[j + 4]; in read_types()
232 tz->type[i].abbr_idx = buffer[j + 5]; in read_types()
234 timelib_free(buffer); in read_types()
264 buffer = (unsigned char*) timelib_malloc(tz->bit32.ttisstdcnt * sizeof(unsigned char)); in read_types()
265 if (!buffer) { in read_types()
268 memcpy(buffer, *tzf, sizeof(unsigned char) * tz->bit32.ttisstdcnt); in read_types()
272 tz->type[i].isstdcnt = buffer[i]; in read_types()
274 timelib_free(buffer); in read_types()
278 buffer = (unsigned char*) timelib_malloc(tz->bit32.ttisgmtcnt * sizeof(unsigned char)); in read_types()
279 if (!buffer) { in read_types()
282 memcpy(buffer, *tzf, sizeof(unsigned char) * tz->bit32.ttisgmtcnt); in read_types()
286 tz->type[i].isgmtcnt = buffer[i]; in read_types()
288 timelib_free(buffer); in read_types()
308 uint32_t buffer[3]; in read_location() local
311 memcpy(&buffer, *tzf, sizeof(buffer)); in read_location()
312 tz->location.latitude = timelib_conv_int_unsigned(buffer[0]); in read_location()
314 tz->location.longitude = timelib_conv_int_unsigned(buffer[1]); in read_location()
316 comments_len = timelib_conv_int_unsigned(buffer[2]); in read_location()
317 *tzf += sizeof(buffer); in read_location()
435 uint32_t buffer[6]; in read_64bit_header() local
437 memcpy(&buffer, *tzf, sizeof(buffer)); in read_64bit_header()
438 tz->bit64.ttisgmtcnt = timelib_conv_int_unsigned(buffer[0]); in read_64bit_header()
439 tz->bit64.ttisstdcnt = timelib_conv_int_unsigned(buffer[1]); in read_64bit_header()
440 tz->bit64.leapcnt = timelib_conv_int_unsigned(buffer[2]); in read_64bit_header()
441 tz->bit64.timecnt = timelib_conv_int_unsigned(buffer[3]); in read_64bit_header()
442 tz->bit64.typecnt = timelib_conv_int_unsigned(buffer[4]); in read_64bit_header()
443 tz->bit64.charcnt = timelib_conv_int_unsigned(buffer[5]); in read_64bit_header()
444 *tzf += sizeof(buffer); in read_64bit_header()