aboutsummaryrefslogtreecommitdiff
path: root/src/daemon/https/tls/gnutls_datum.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/daemon/https/tls/gnutls_datum.c')
-rw-r--r--src/daemon/https/tls/gnutls_datum.c33
1 files changed, 0 insertions, 33 deletions
diff --git a/src/daemon/https/tls/gnutls_datum.c b/src/daemon/https/tls/gnutls_datum.c
index a62c4204..2f03da3b 100644
--- a/src/daemon/https/tls/gnutls_datum.c
+++ b/src/daemon/https/tls/gnutls_datum.c
@@ -49,23 +49,6 @@ MHD_gtls_write_datum24 (opaque * dest, MHD_gnutls_datum_t dat)
49 memcpy (&dest[3], dat.data, dat.size); 49 memcpy (&dest[3], dat.data, dat.size);
50} 50}
51 51
52void
53MHD_gtls_write_datum32 (opaque * dest, MHD_gnutls_datum_t dat)
54{
55 MHD_gtls_write_uint32 (dat.size, dest);
56 if (dat.data != NULL)
57 memcpy (&dest[4], dat.data, dat.size);
58}
59
60void
61MHD_gtls_write_datum8 (opaque * dest, MHD_gnutls_datum_t dat)
62{
63 dest[0] = (uint8_t) dat.size;
64 if (dat.data != NULL)
65 memcpy (&dest[1], dat.data, dat.size);
66}
67
68
69int 52int
70MHD_gtls_set_datum_m (MHD_gnutls_datum_t * dat, const void *data, 53MHD_gtls_set_datum_m (MHD_gnutls_datum_t * dat, const void *data,
71 size_t data_size, MHD_gnutls_alloc_function galloc_func) 54 size_t data_size, MHD_gnutls_alloc_function galloc_func)
@@ -87,22 +70,6 @@ MHD_gtls_set_datum_m (MHD_gnutls_datum_t * dat, const void *data,
87 return 0; 70 return 0;
88} 71}
89 72
90int
91MHD_gtls_datum_append_m (MHD_gnutls_datum_t * dst, const void *data,
92 size_t data_size,
93 MHD_gnutls_realloc_function grealloc_func)
94{
95
96 dst->data = grealloc_func (dst->data, data_size + dst->size);
97 if (dst->data == NULL)
98 return GNUTLS_E_MEMORY_ERROR;
99
100 memcpy (&dst->data[dst->size], data, data_size);
101 dst->size += data_size;
102
103 return 0;
104}
105
106void 73void
107MHD_gtls_free_datum_m (MHD_gnutls_datum_t * dat, 74MHD_gtls_free_datum_m (MHD_gnutls_datum_t * dat,
108 MHD_gnutls_free_function gfree_func) 75 MHD_gnutls_free_function gfree_func)