Lines Matching refs:ptr
38 char* ptr = static_cast<char*>( malloc( 4 + block_size * 6 ) ); in block32_new() local
40 if ( ptr ) { in block32_new()
42 *(reinterpret_cast<uint32_t*>(ptr)) = initial_position; in block32_new()
43 *block_ptr = ptr + 4; in block32_new()
46 return ptr; in block32_new()
56 char* ptr = static_cast<char*>( malloc( 8 + block_size * 10 ) ); in block64_new() local
58 if ( ptr ) { in block64_new()
60 *(reinterpret_cast<uint64_t*>(ptr)) = initial_position; in block64_new()
61 *block_ptr = ptr + 8; in block64_new()
64 return ptr; in block64_new()
70 void block_add_one_byte_relative( char** ptr, uint8_t value ) in block_add_one_byte_relative() argument
72 **ptr = value; in block_add_one_byte_relative()
73 *ptr += sizeof( value ); in block_add_one_byte_relative()
78 void block_add_two_bytes_relative( char** ptr, uint16_t value ) in block_add_two_bytes_relative() argument
83 … *(reinterpret_cast<uint16_t*>(*ptr)) = qToBigEndian( static_cast<uint16_t>( value | (1 << 15) ) ); in block_add_two_bytes_relative()
84 *ptr += sizeof( value ); in block_add_two_bytes_relative()
88 void block32_add_absolute( char** ptr, uint32_t value ) in block32_add_absolute() argument
91 *(reinterpret_cast<uint16_t*>(*ptr)) = 0xFF; in block32_add_absolute()
92 *ptr += sizeof( uint16_t ); in block32_add_absolute()
94 *(reinterpret_cast<uint32_t*>(*ptr)) = value; in block32_add_absolute()
95 *ptr += sizeof( uint32_t ); in block32_add_absolute()
100 uint64_t block32_initial_pos( char* block, char** ptr ) in block32_initial_pos() argument
102 *ptr = block + sizeof( uint32_t ); in block32_initial_pos()
108 uint64_t block32_next_pos( char** ptr, uint64_t previous_pos ) in block32_next_pos() argument
112 uint8_t byte = **ptr; in block32_next_pos()
113 ++(*ptr); in block32_next_pos()
120 uint8_t lo_byte = **ptr; in block32_next_pos()
121 ++(*ptr); in block32_next_pos()
129 ++(*ptr); in block32_next_pos()
131 pos = *(reinterpret_cast<uint32_t*>(*ptr)); in block32_next_pos()
132 *ptr += sizeof( uint32_t ); in block32_next_pos()
139 void block64_add_absolute( char** ptr, uint64_t value ) in block64_add_absolute() argument
144 *(reinterpret_cast<uint16_t*>(*ptr)) = 0xFF; in block64_add_absolute()
145 *ptr += sizeof( uint16_t ); in block64_add_absolute()
147 *(reinterpret_cast<uint64_t*>(*ptr)) = value; in block64_add_absolute()
148 *ptr += sizeof( uint64_t ); in block64_add_absolute()
153 uint64_t block64_initial_pos( char* block, char** ptr ) in block64_initial_pos() argument
155 *ptr = block + sizeof( uint64_t ); in block64_initial_pos()
161 uint64_t block64_next_pos( char** ptr, uint64_t previous_pos ) in block64_next_pos() argument
165 uint8_t byte = **ptr; in block64_next_pos()
166 ++(*ptr); in block64_next_pos()
173 uint8_t lo_byte = **ptr; in block64_next_pos()
174 ++(*ptr); in block64_next_pos()
182 ++(*ptr); in block64_next_pos()
184 pos = *(reinterpret_cast<uint64_t*>(*ptr)); in block64_next_pos()
185 *ptr += sizeof( uint64_t ); in block64_next_pos()
337 char* ptr; in at() local
345 ptr = last_read->ptr; in at()
347 position = block32_next_pos( &ptr, position ); in at()
351 position = block32_initial_pos( block, &ptr ); in at()
355 position = block32_next_pos( &ptr, position ); in at()
363 ptr = last_read->ptr; in at()
365 position = block64_next_pos( &ptr, position ); in at()
369 position = block64_initial_pos( block, &ptr ); in at()
373 position = block64_next_pos( &ptr, position ); in at()
381 last_read->ptr = ptr; in at()