diff options
Diffstat (limited to 'src/libstddjb/cdb_p.c')
-rw-r--r-- | src/libstddjb/cdb_p.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/libstddjb/cdb_p.c b/src/libstddjb/cdb_p.c new file mode 100644 index 0000000..9e46292 --- /dev/null +++ b/src/libstddjb/cdb_p.c @@ -0,0 +1,9 @@ +/* ISC license. */ + +#include <skalibs/cdb.h> +#include "cdb-internal.h" + +char const *cdb_p (cdb const *c, uint32_t len, uint32_t pos) +{ + return pos <= c->size && len <= c->size - pos ? c->map + pos : 0 ; +} |