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

Function md_config_set_store_locks

modules/md/mod_md_config.c:751–779  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

749}
750
751static const char *md_config_set_store_locks(cmd_parms *cmd, void *dc, const char *s)
752{
753 md_srv_conf_t *config = md_config_get(cmd->server);
754 const char *err = md_conf_check_location(cmd, MD_LOC_NOT_MD);
755 int use_store_locks;
756 apr_time_t wait_time = 0;
757
758 (void)dc;
759 if (err) {
760 return err;
761 }
762 else if (!apr_cstr_casecmp("off", s)) {
763 use_store_locks = 0;
764 }
765 else if (!apr_cstr_casecmp("on", s)) {
766 use_store_locks = 1;
767 }
768 else {
769 if (md_duration_parse(&wait_time, s, "s") != APR_SUCCESS) {
770 return "neither 'on', 'off' or a duration specified";
771 }
772 use_store_locks = (wait_time != 0);
773 }
774 config->mc->use_store_locks = use_store_locks;
775 if (wait_time) {
776 config->mc->lock_wait_timeout = wait_time;
777 }
778 return NULL;
779}
780
781static const char *md_config_set_match_mode(cmd_parms *cmd, void *dc, const char *s)
782{

Callers

nothing calls this directly

Calls 3

md_config_getFunction · 0.85
md_conf_check_locationFunction · 0.85
md_duration_parseFunction · 0.85

Tested by

no test coverage detected