Merge branch '2.3' into 2.4
This commit is contained in:
		@ -2124,6 +2124,21 @@ static bool validate_object_json(json_t* json,
 | 
			
		||||
 | 
			
		||||
    if (is_valid_resource_body(json))
 | 
			
		||||
    {
 | 
			
		||||
        if (json_t* parameters = mxs_json_pointer(json, MXS_JSON_PTR_PARAMETERS))
 | 
			
		||||
        {
 | 
			
		||||
            const char* key;
 | 
			
		||||
            json_t* value;
 | 
			
		||||
 | 
			
		||||
            json_object_foreach(parameters, key, value)
 | 
			
		||||
            {
 | 
			
		||||
                if (json_is_string(value) && strchr(json_string_value(value), '\n'))
 | 
			
		||||
                {
 | 
			
		||||
                    config_runtime_error("Parameter '%s' contains unescaped newlines", key);
 | 
			
		||||
                    return false;
 | 
			
		||||
                }
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        if (!(value = mxs_json_pointer(json, MXS_JSON_PTR_ID)))
 | 
			
		||||
        {
 | 
			
		||||
            config_runtime_error("Value not found: '%s'", MXS_JSON_PTR_ID);
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user