Changeset 08c48d7 in mod_gnutls for src/gnutls_util.h


Ignore:
Timestamp:
Jan 2, 2019, 3:22:48 PM (21 months ago)
Author:
Fiona Klute <fiona.klute@…>
Branches:
debian/master, master, proxy-ticket
Children:
4d38cbd
Parents:
c7710cf
Message:

Extract code for turning APR array of strings into gnutls_datum_t array

Having it as a separate function will allow sharing the code between
server and client (proxy) side ALPN proposal handling.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/gnutls_util.h

    rc7710cf r08c48d7  
    9696void mgs_default_priority_deinit();
    9797
     98/**
     99 * Create a shallow copy of an APR array of `char *` into a new array
     100 * of gnutls_datum_t, filling `size` via `strlen()`. "Shallow copy"
     101 * means that the strings themselves are not copied, just the pointers
     102 * to them.
     103 *
     104 * @param src array to copy
     105 * @param pool allocate memory for the new array
     106 * @param min_elements allocate room for at least this many elements
     107 *
     108 * @return pointer to the first element of the new array
     109 */
     110gnutls_datum_t * mgs_str_array_to_datum_array(const apr_array_header_t *src,
     111                                              apr_pool_t *pool,
     112                                              const int min_elements);
     113
    98114#endif /* __MOD_GNUTLS_UTIL_H__ */
Note: See TracChangeset for help on using the changeset viewer.