LCOV - code coverage report
Current view: top level - basic - hexdecoct.h (source / functions) Hit Total Coverage
Test: main_coverage.info Lines: 4 4 100.0 %
Date: 2019-08-22 15:41:25 Functions: 2 2 100.0 %

          Line data    Source code
       1             : /* SPDX-License-Identifier: LGPL-2.1+ */
       2             : #pragma once
       3             : 
       4             : #include <stdbool.h>
       5             : #include <stddef.h>
       6             : #include <stdio.h>
       7             : #include <sys/types.h>
       8             : 
       9             : #include "macro.h"
      10             : 
      11             : char octchar(int x) _const_;
      12             : int unoctchar(char c) _const_;
      13             : 
      14             : char decchar(int x) _const_;
      15             : int undecchar(char c) _const_;
      16             : 
      17             : char hexchar(int x) _const_;
      18             : int unhexchar(char c) _const_;
      19             : 
      20             : char *hexmem(const void *p, size_t l);
      21             : int unhexmem_full(const char *p, size_t l, bool secure, void **mem, size_t *len);
      22          12 : static inline int unhexmem(const char *p, size_t l, void **mem, size_t *len) {
      23          12 :         return unhexmem_full(p, l, false, mem, len);
      24             : }
      25             : 
      26             : char base32hexchar(int x) _const_;
      27             : int unbase32hexchar(char c) _const_;
      28             : 
      29             : char base64char(int x) _const_;
      30             : int unbase64char(char c) _const_;
      31             : 
      32             : char *base32hexmem(const void *p, size_t l, bool padding);
      33             : int unbase32hexmem(const char *p, size_t l, bool padding, void **mem, size_t *len);
      34             : 
      35             : ssize_t base64mem(const void *p, size_t l, char **out);
      36             : int base64_append(char **prefix, int plen,
      37             :                   const void *p, size_t l,
      38             :                   int margin, int width);
      39             : int unbase64mem_full(const char *p, size_t l, bool secure, void **mem, size_t *len);
      40          20 : static inline int unbase64mem(const char *p, size_t l, void **mem, size_t *len) {
      41          20 :         return unbase64mem_full(p, l, false, mem, len);
      42             : }
      43             : 
      44             : void hexdump(FILE *f, const void *p, size_t s);

Generated by: LCOV version 1.14