* skips @count integers from the current position in the received binary packet * * @return: * 0: success * < 0: error, buffer limit reached */
| 272 | * < 0: error, buffer limit reached |
| 273 | */ |
| 274 | int bin_skip_int(bin_packet_t *packet, int count) |
| 275 | { |
| 276 | if (packet->front_pointer - packet->buffer.s + count * sizeof(int) > |
| 277 | packet->buffer.len) { |
| 278 | packet->front_pointer = packet->buffer.s + packet->buffer.len; |
| 279 | LM_ERR("Buffer limit reached\n"); |
| 280 | return -1; |
| 281 | } |
| 282 | packet->front_pointer += count * sizeof(int); |
| 283 | |
| 284 | return 0; |
| 285 | } |
| 286 | |
| 287 | /* |
| 288 | * skips @count strings from the current position in a received binary packet |
no outgoing calls
no test coverage detected