ext/nginx/MergeLocationConfig.c in passenger-4.0.60 vs ext/nginx/MergeLocationConfig.c in passenger-5.0.0.beta1

- old
+ new

@@ -1,8 +1,8 @@ /* * Phusion Passenger - https://www.phusionpassenger.com/ - * Copyright (c) 2010-2013 Phusion + * Copyright (c) 2010-2014 Phusion * * "Phusion Passenger" is a trademark of Hongli Lai & Ninh Bui. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -98,10 +98,18 @@ prev->start_timeout, NGX_CONF_UNSET); + if (merge_string_array(cf, &prev->base_uris, &conf->base_uris) != NGX_OK) { + ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, + "cannot merge \"passenger_base_uri\" configurations"); + return NGX_CONF_ERROR; + } + + + ngx_conf_merge_str_value(conf->document_root, prev->document_root, NULL); @@ -140,24 +148,46 @@ prev->union_station_support, NGX_CONF_UNSET); - ngx_conf_merge_value(conf->debugger, - prev->debugger, - NGX_CONF_UNSET); + if (merge_string_array(cf, &prev->union_station_filters, &conf->union_station_filters) != NGX_OK) { + ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, + "cannot merge \"union_station_filter\" configurations"); + return NGX_CONF_ERROR; + } - ngx_conf_merge_value(conf->show_version_in_header, - prev->show_version_in_header, + ngx_conf_merge_value(conf->debugger, + prev->debugger, NGX_CONF_UNSET); ngx_conf_merge_value(conf->max_preloader_idle_time, prev->max_preloader_idle_time, NGX_CONF_UNSET); + + + + if (merge_string_keyval_table(cf, &prev->env_vars, &conf->env_vars) != NGX_OK) { + ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, + "cannot merge \"passenger_env_var\" configurations"); + return NGX_CONF_ERROR; + } + + + + ngx_conf_merge_uint_value(conf->headers_hash_max_size, + prev->headers_hash_max_size, + 512); + + + + ngx_conf_merge_uint_value(conf->headers_hash_bucket_size, + prev->headers_hash_bucket_size, + 64); ngx_conf_merge_str_value(conf->spawn_method, prev->spawn_method,