Lines Matching defs:mem
56 BIO *mem; /* Mem BIO holding request header or response */
111 /* everything else is 0, e.g. rctx->len_to_send, or NULL, e.g. rctx->mem */
127 BIO_free(rctx->mem);
143 return rctx->mem;
177 BIO_free(rctx->mem);
178 if ((rctx->mem = BIO_new(BIO_s_mem())) == NULL)
182 if (BIO_printf(rctx->mem, "%s ", rctx->method_POST ? "POST" : "GET") <= 0)
190 if (BIO_printf(rctx->mem, OSSL_HTTP_PREFIX"%s", server) <= 0)
192 if (port != NULL && BIO_printf(rctx->mem, ":%s", port) <= 0)
199 if (path[0] != '/' && BIO_printf(rctx->mem, "/") <= 0)
205 if (BIO_printf(rctx->mem, "%s "HTTP_1_0"\r\n", path) <= 0)
220 if (rctx->mem == NULL) {
225 if (BIO_puts(rctx->mem, name) <= 0)
228 if (BIO_write(rctx->mem, ": ", 2) != 2)
230 if (BIO_puts(rctx->mem, value) <= 0)
233 return BIO_write(rctx->mem, "\r\n", 2) == 2;
293 && BIO_printf(rctx->mem, "Content-Type: %s\r\n", content_type) <= 0)
321 && BIO_printf(rctx->mem, "Content-Length: %ld\r\n", req_len) < 0)
333 BIO *mem = NULL;
337 res = (mem = ASN1_item_i2d_mem_bio(it, req)) != NULL;
338 res = res && set1_content(rctx, content_type, mem);
339 BIO_free(mem);
525 if (rctx->mem == NULL || rctx->wbio == NULL || rctx->rbio == NULL) {
554 if (BIO_write(rctx->mem, rctx->buf, n) != n)
561 if (BIO_write(rctx->mem, "\r\n", 2) != 2) {
569 rctx->len_to_send = BIO_get_mem_data(rctx->mem, &rctx->pos);
574 /* Copy some chunk of data from rctx->mem to rctx->wbio */
591 (void)BIO_reset(rctx->mem);
638 n = BIO_get_mem_data(rctx->mem, &p);
646 n = BIO_gets(rctx->mem, buf, rctx->buf_size);
649 if (BIO_should_retry(rctx->mem))
776 n = BIO_get_mem_data(rctx->mem, &p);
818 n = BIO_get_mem_data(rctx->mem, NULL);
836 *pval = ASN1_item_d2i(NULL, &p, BIO_get_mem_data(rctx->mem, &p), it);
905 return rctx->state == OHS_STREAM ? rctx->rbio : rctx->mem;