summaryrefslogtreecommitdiff
path: root/src/libstddjb/cbuffer_rseek.c
blob: 9454c71cb762bb2270b581a03e377ee7e820d661 (plain)
1
2
3
4
5
6
7
8
9
10
/* ISC license. */

#include <skalibs/cbuffer.h>

size_t cbuffer_rseek (cbuffer_t *b, size_t len)
{
  size_t max = cbuffer_len(b) ;
  if (len > max) len = max ;
  return cbuffer_RSEEK(b, len) ;
}