ext/iodine/http1_parser.h
/* a helper that seeks any char, converts it to NUL and returns 1 if found. */
a helper that seeks any char, converts it to NUL and returns 1 if found.
a helper that seeks any char converts it to NUL and returns 1 if found .
inline static uint8_t seek2ch(uint8_t **pos, uint8_t *const limit, uint8_t ch) {
  if (*pos >= limit)
    return 0;
  if (**pos == ch) {
    return 1;
  }
  uint8_t *tmp = memchr(*pos, ch, limit - (*pos));
  if (tmp) {
    *pos = tmp;
    return 1;
  }
  *pos = limit;
  return 0;
}
inline static uint8_t seek2ch ( uint8_t * * pos , uint8_t * const limit , uint8_t ch ) { if ( * pos >= limit ) return 0 ; if ( * * pos == ch ) { return 1 ; } uint8_t * tmp = memchr ( * pos , ch , limit - ( * pos ) ) ; if ( tmp ) { * pos = tmp ; return 1 ; } * pos = limit ; return 0 ; }
a helper that seeks any char, converts it to NUL and returns 1 if found.
a helper that seeks any char converts it to NUL and returns 1 if found .
/* This is library based alternative that is sometimes slower  */