1414#include "ngx_http_upstream_check_module.h"
1515#endif
1616
17+ #if nginx_version > 1027003
18+ #ifdef NGX_HTTP_UPSTREAM_MODIFY // for freenginx
1719static u_char *
1820ngx_http_vhost_traffic_status_display_ug_host (
1921 ngx_http_request_t * r ,
@@ -22,6 +24,8 @@ ngx_http_vhost_traffic_status_display_ug_host(
2224 ngx_rbtree_node_t * sentinel ,
2325 ngx_http_upstream_rr_peers_t * peers ,
2426 u_char * buf );
27+ #endif
28+ #endif
2529
2630u_char *
2731ngx_http_vhost_traffic_status_display_set_main (ngx_http_request_t * r ,
@@ -616,6 +620,7 @@ ngx_http_vhost_traffic_status_display_set_upstream_group(ngx_http_request_t *r,
616620 zone = 1 ;
617621
618622#if nginx_version > 1027003
623+ #ifdef NGX_HTTP_UPSTREAM_MODIFY // for freenginx
619624 if (uscf -> flags & NGX_HTTP_UPSTREAM_MODIFY ) {
620625 peers = uscf -> peer .data ;
621626 buf = ngx_http_vhost_traffic_status_display_ug_host (r , uscf -> host , ctx -> rbtree -> root , ctx -> rbtree -> sentinel , peers , buf );
@@ -667,6 +672,7 @@ ngx_http_vhost_traffic_status_display_set_upstream_group(ngx_http_request_t *r,
667672 }
668673 }
669674 goto last ;
675+ #endif
670676#endif
671677
672678 peers = uscf -> peer .data ;
@@ -780,7 +786,11 @@ ngx_http_vhost_traffic_status_display_set_upstream_group(ngx_http_request_t *r,
780786 }
781787 }
782788
789+ #if nginx_version > 1027003
790+ #ifdef NGX_HTTP_UPSTREAM_MODIFY // for freenginx
783791last :
792+ #endif
793+ #endif
784794 if (s == buf ) {
785795 buf = o ;
786796
@@ -1002,6 +1012,8 @@ ngx_http_vhost_traffic_status_display_set(ngx_http_request_t *r,
10021012 return buf ;
10031013}
10041014
1015+ #if nginx_version > 1027003
1016+ #ifdef NGX_HTTP_UPSTREAM_MODIFY // for freenginx
10051017static u_char *
10061018ngx_http_vhost_traffic_status_display_ug_host (
10071019 ngx_http_request_t * r ,
@@ -1062,4 +1074,6 @@ ngx_http_vhost_traffic_status_display_ug_host(
10621074 }
10631075 return buf ;
10641076}
1077+ #endif
1078+ #endif
10651079/* vi:set ft=c ts=4 sw=4 et fdm=marker: */
0 commit comments