trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kic...@apache.org
Subject git commit: [TS-2489] add back comment
Date Sun, 12 Jan 2014 08:15:37 GMT
Updated Branches:
  refs/heads/master 793331a31 -> 586469fc6


[TS-2489] add back comment


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

Branch: refs/heads/master
Commit: 586469fc6389cfda4f3af1bfa47eb4fed099eb69
Parents: 793331a
Author: Yu Qing <zhuangyuan@taobao.com>
Authored: Sun Jan 12 00:15:42 2014 -0800
Committer: Kit Chan <kichan@apache.org>
Committed: Sun Jan 12 00:15:42 2014 -0800

----------------------------------------------------------------------
 plugins/experimental/esi/lib/EsiProcessor.cc | 10 ++++++++++
 1 file changed, 10 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/586469fc/plugins/experimental/esi/lib/EsiProcessor.cc
----------------------------------------------------------------------
diff --git a/plugins/experimental/esi/lib/EsiProcessor.cc b/plugins/experimental/esi/lib/EsiProcessor.cc
index 3ece0f4..77f13b0 100644
--- a/plugins/experimental/esi/lib/EsiProcessor.cc
+++ b/plugins/experimental/esi/lib/EsiProcessor.cc
@@ -720,6 +720,16 @@ EsiProcessor::_preprocess(DocNodeList &node_list, int &n_prescanned_nodes)
{
         _debugLog(_debug_tag, "[%s] handled try node successfully", __FUNCTION__);
         break;
       case DocNode::TYPE_HTML_COMMENT:
+        /**
+         * the html comment <!--esi innertext--> is a container.
+         * the esi processor will remove the starting tag "<!--esi" and the
+         * closure tag "-->", then keep the innertext (the content within it).
+         *
+         * we should call _handleHtmlComment when the node list is parsed
+         * from the content,
+         * but we should NOT call _handleHtmlComment again when the node list
+         * is unpacked from the cache because the node list has been parsed.
+         */
         if (!_usePackedNodeList && !_handleHtmlComment(list_iter)) {
           _errorLog("[%s] Failed to preprocess try node", __FUNCTION__);
           return false;


Mime
View raw message