git-2.22.0/trace2/tr2_cfg.c
/*
 * See if the given config key matches any of our patterns of interest.
 */
See if the given config key matches any of our patterns of interest.
See if the given config key matches any of our patterns of interest .
static int tr2_cfg_cb(const char *key, const char *value, void *d)
{
	struct strbuf **s;
	struct tr2_cfg_data *data = (struct tr2_cfg_data *)d;
	for (s = tr2_cfg_patterns; *s; s++) {
		struct strbuf *buf = *s;
		int wm = wildmatch(buf->buf, key, WM_CASEFOLD);
		if (wm == WM_MATCH) {
			trace2_def_param_fl(data->file, data->line, key, value);
			return 0;
		}
	}
	return 0;
}
static int tr2_cfg_cb ( const char * key , const char * value , void * d ) { struct strbuf * * s ; struct tr2_cfg_data * data = ( struct tr2_cfg_data * ) d ; for ( s = tr2_cfg_patterns ; * s ; s ++ ) { struct strbuf * buf = * s ; int wm = wildmatch ( buf -> buf , key , WM_CASEFOLD ) ; if ( wm == WM_MATCH ) { trace2_def_param_fl ( data -> file , data -> line , key , value ) ; return 0 ; } } return 0 ; }
See if the given config key matches any of our patterns of interest.
See if the given config key matches any of our patterns of interest .