MCPcopy Create free account
hub / github.com/apache/httpd / md_reg_set_props

Function md_reg_set_props

modules/md/md_reg.c:770–786  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

768/* syncing */
769
770apr_status_t md_reg_set_props(md_reg_t *reg, apr_pool_t *p, int can_http, int can_https)
771{
772 if (reg->can_http != can_http || reg->can_https != can_https) {
773 md_json_t *json;
774
775 if (reg->domains_frozen) return APR_EACCES;
776 reg->can_http = can_http;
777 reg->can_https = can_https;
778
779 json = md_json_create(p);
780 md_json_setb(can_http, json, MD_KEY_PROTO, MD_KEY_HTTP, NULL);
781 md_json_setb(can_https, json, MD_KEY_PROTO, MD_KEY_HTTPS, NULL);
782
783 return md_store_save(reg->store, p, MD_SG_NONE, NULL, MD_FN_HTTPD_JSON, MD_SV_JSON, json, 0);
784 }
785 return APR_SUCCESS;
786}
787
788static md_t *find_closest_match(apr_array_header_t *mds, const md_t *md)
789{

Callers 1

Calls 3

md_json_createFunction · 0.85
md_json_setbFunction · 0.85
md_store_saveFunction · 0.85

Tested by

no test coverage detected