You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by zw...@apache.org on 2014/04/17 18:44:30 UTC

[31/50] git commit: TS-2717 header-rewrite set-redirect not working

TS-2717 header-rewrite set-redirect not working


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/9b236f12
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/9b236f12
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/9b236f12

Branch: refs/heads/5.0.x
Commit: 9b236f1247289fc46ecb1cd2511e7a477a921138
Parents: b76b23c
Author: Igor Brezac <ig...@ypass.net>
Authored: Tue Apr 15 10:34:19 2014 -0600
Committer: Leif Hedstrom <zw...@apache.org>
Committed: Tue Apr 15 10:34:19 2014 -0600

----------------------------------------------------------------------
 plugins/header_rewrite/operators.cc | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/9b236f12/plugins/header_rewrite/operators.cc
----------------------------------------------------------------------
diff --git a/plugins/header_rewrite/operators.cc b/plugins/header_rewrite/operators.cc
index 7b3beb5..e22ab51 100644
--- a/plugins/header_rewrite/operators.cc
+++ b/plugins/header_rewrite/operators.cc
@@ -298,6 +298,9 @@ OperatorSetRedirect::exec(const Resources& res) const
       }
 
       TSHttpTxnSetHttpRetStatus(res.txnp,(TSHttpStatus)_status.get_int_value());
+      const_cast<Resources&>(res).changed_url = true;
+      res._rri->redirect = 1;
+
       //TSHttpHdrStatusSet(res.bufp, res.hdr_loc, (TSHttpStatus)_status.get_int_value());
       const char *start = value.c_str();
       const char *end = value.size() + start;