You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by ni...@apache.org on 2012/03/15 13:16:57 UTC
git commit: Make replace-header plugin work (at least a little bit).
Updated Branches:
refs/heads/master 64f2131c1 -> 2cebb2657
Make replace-header plugin work (at least a little bit).
Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/2cebb265
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/2cebb265
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/2cebb265
Branch: refs/heads/master
Commit: 2cebb2657ee21843ac3f7cecf75d22323b0b3317
Parents: 64f2131
Author: Nick Kew <nk...@qualys.com>
Authored: Thu Mar 15 12:12:28 2012 +0000
Committer: Nick Kew <nk...@qualys.com>
Committed: Thu Mar 15 12:12:28 2012 +0000
----------------------------------------------------------------------
example/replace-header/replace-header.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/trafficserver/blob/2cebb265/example/replace-header/replace-header.c
----------------------------------------------------------------------
diff --git a/example/replace-header/replace-header.c b/example/replace-header/replace-header.c
index 8745f71..4d1c03c 100644
--- a/example/replace-header/replace-header.c
+++ b/example/replace-header/replace-header.c
@@ -25,6 +25,8 @@
* replace-header.c:
* an example program...
*
+ * NOTE: If faced with duplicate headers, this will only detect the
+ * first instance. Operational plugins may need to do more!
*
* Usage:
*
@@ -42,7 +44,7 @@ replace_header(TSHttpTxn txnp, TSCont contp)
TSMLoc resp_loc;
TSMLoc field_loc;
- if (!TSHttpTxnServerRespGet(txnp, &resp_bufp, &resp_loc)) {
+ if (TSHttpTxnServerRespGet(txnp, &resp_bufp, &resp_loc) != TS_SUCCESS) {
TSError("couldn't retrieve server response header.\n");
goto done;
}