[jira] [Commented] (TS-4099) replace XML statistics with Lua
[ https://issues.apache.org/jira/browse/TS-4099?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15104127#comment-15104127 ] ASF GitHub Bot commented on TS-4099: Github user jpeach commented on a diff in the pull request: https://github.com/apache/trafficserver/pull/422#discussion_r49960411 --- Diff: lib/bindings/repl.cc --- @@ -0,0 +1,60 @@ +/** @file + * + * Lua bindings REPL. + * + * @section license License + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "ink_autoconf.h" +#include "bindings.h" +#include + +#if HAVE_READLINE_H +#include +#endif + +void +repl(BindingInstance ) --- End diff -- Something like this (in a command-line program): ```C Binding binding; add_my_lua_api(binding); repl(binding); // noreturn ``` And then you have a command line shell to evaluate your API. > replace XML statistics with Lua > --- > > Key: TS-4099 > URL: https://issues.apache.org/jira/browse/TS-4099 > Project: Traffic Server > Issue Type: New Feature > Components: Lua, Manager, Metrics >Reporter: James Peach >Assignee: James Peach > Fix For: 6.2.0 > > > The custom metrics XML format is undocumented and difficult to use and > extend. Since we plan to use Lua for configuration programmability, lets make > a start by replacing this subsystem with Lua. > It turns out that Lua is mostly more readable and easier to understand. > Performance is roughly similar. > Example syntax: > {code} > float 'proxy.node.user_agent_total_bytes_avg_10s' [[ > local self = ... > return interval_delta_of_10s(self, function() > return proxy.node.user_agent_total_bytes > end) > ]] > counter 'proxy.node.origin_server_total_bytes' [[ > return proxy.node.http.origin_server_total_request_bytes + > proxy.node.http.origin_server_total_response_bytes + > proxy.node.http.parent_proxy_total_request_bytes + > proxy.node.http.parent_proxy_total_response_bytes > ]] > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4099) replace XML statistics with Lua
[ https://issues.apache.org/jira/browse/TS-4099?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15104110#comment-15104110 ] ASF GitHub Bot commented on TS-4099: Github user shukitchan commented on a diff in the pull request: https://github.com/apache/trafficserver/pull/422#discussion_r49959828 --- Diff: lib/bindings/repl.cc --- @@ -0,0 +1,60 @@ +/** @file + * + * Lua bindings REPL. + * + * @section license License + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "ink_autoconf.h" +#include "bindings.h" +#include + +#if HAVE_READLINE_H +#include +#endif + +void +repl(BindingInstance ) --- End diff -- so nothing is using it now. can you later show us an example of how this can be used? > replace XML statistics with Lua > --- > > Key: TS-4099 > URL: https://issues.apache.org/jira/browse/TS-4099 > Project: Traffic Server > Issue Type: New Feature > Components: Lua, Manager, Metrics >Reporter: James Peach >Assignee: James Peach > Fix For: 6.2.0 > > > The custom metrics XML format is undocumented and difficult to use and > extend. Since we plan to use Lua for configuration programmability, lets make > a start by replacing this subsystem with Lua. > It turns out that Lua is mostly more readable and easier to understand. > Performance is roughly similar. > Example syntax: > {code} > float 'proxy.node.user_agent_total_bytes_avg_10s' [[ > local self = ... > return interval_delta_of_10s(self, function() > return proxy.node.user_agent_total_bytes > end) > ]] > counter 'proxy.node.origin_server_total_bytes' [[ > return proxy.node.http.origin_server_total_request_bytes + > proxy.node.http.origin_server_total_response_bytes + > proxy.node.http.parent_proxy_total_request_bytes + > proxy.node.http.parent_proxy_total_response_bytes > ]] > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4099) replace XML statistics with Lua
[ https://issues.apache.org/jira/browse/TS-4099?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15104131#comment-15104131 ] ASF GitHub Bot commented on TS-4099: Github user jpeach commented on a diff in the pull request: https://github.com/apache/trafficserver/pull/422#discussion_r49960578 --- Diff: cmd/traffic_manager/metrics.cc --- @@ -0,0 +1,385 @@ +/** @file + * + * Traffic Manager custom metrics. + * + * @section license License + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "ts/ink_config.h" +#include "ts/ink_memory.h" +#include "ts/Ptr.h" +#include "ts/Vec.h" +#include "ts/I_Layout.h" +#include "bindings/bindings.h" +#include "bindings/metrics.h" +#include "I_RecCore.h" +#include "MgmtDefs.h" +#include "MgmtUtils.h" +#include "WebOverview.h" +#include "metrics.h" + +struct Evaluator { + Evaluator() : rec_name(NULL), data_type(RECD_NULL), ref(-1) {} + + ~Evaluator() + { +ats_free(this->rec_name); +ink_release_assert(this->ref == -1); + } + + bool + bind(lua_State *L, const char *metric, const char *expression) + { +if (RecGetRecordDataType(metric, >data_type) != REC_ERR_OKAY) { + return false; +} + +this->rec_name = ats_strdup(metric); + +switch (luaL_loadstring(L, expression)) { +case LUA_ERRSYNTAX: +case LUA_ERRMEM: + Debug("lua", "loadstring failed for %s", metric); + luaL_error(L, "invalid expression for %s", metric); + return false; +case 0: + break; // success +} + +// The loaded chunk is now on the top of the stack. Stuff it into the registry +// so we can evaluate it later. +this->ref = luaL_ref(L, LUA_REGISTRYINDEX); + +return true; + } + + void + eval(lua_State *L) const + { +// Push the stashed expression chunk onto the stack. +lua_rawgeti(L, LUA_REGISTRYINDEX, this->ref); + +// Evaluate it. Note that we don't emit a warning for +// evaluation errors. This is because not all metrics (eg. +// cache metrics) are available early in startup so we don't +// want to log spurious warning. Unfortunately it means that +// to check your config for errors you need to enable +// diagnostic tags. +lua_pushstring(L, this->rec_name); +if (lua_pcall(L, 1 /* nargs */, 1 /* nresults */, 0) != 0) { + Debug("lua", "failed to evaluate %s: %s", this->rec_name, lua_tostring(L, -1)); + lua_pop(L, 1); + return; +} + +// If we got a return value, set it on the record. Records can return nil to +// indicate they don't want to be set on this round. +if (!lua_isnil(L, -1)) { + RecData rec_value; + + switch (this->data_type) { + case RECD_INT: +rec_value.rec_int = lua_tointeger(L, -1); +break; + case RECD_COUNTER: +rec_value.rec_counter = lua_tointeger(L, -1); +break; + case RECD_FLOAT: +// Lua will eval 0/0 to NaN rather than 0. +rec_value.rec_float = lua_tonumber(L, -1); +if (isnan(rec_value.rec_float)) { + rec_value.rec_float = 0.0; +} +break; + default: +goto done; + } + + RecSetRecord(RECT_NULL, this->rec_name, this->data_type, _value, NULL, REC_SOURCE_EXPLICIT); +} + + done: +// Pop the return value. +lua_pop(L, 1); + } + +private: + char *rec_name; + RecDataT data_type; + + int ref; +}; + +struct EvaluatorList { + EvaluatorList() : update(true), passes(0) {} + ~EvaluatorList() + { +forv_Vec(Evaluator, e, this->evaluators) { delete e; } + } + + void + push_back(Evaluator *e) + {
[jira] [Commented] (TS-4106) Cache Inspector fails to split multiline URLs
[ https://issues.apache.org/jira/browse/TS-4106?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15104169#comment-15104169 ] ASF subversion and git services commented on TS-4106: - Commit 507dbaf62e3109495fb6aab1938e1b1d7d908ba3 in trafficserver's branch refs/heads/6.1.x from [~zwoop] [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=507dbaf ] TS-4140 Fixes a coverity warning due to changes in TS-4106 (dead code) This closes #427. > Cache Inspector fails to split multiline URLs > - > > Key: TS-4106 > URL: https://issues.apache.org/jira/browse/TS-4106 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Hiroaki Nakamura >Assignee: Leif Hedstrom > Fix For: 6.1.0 > > Attachments: cache_inspector_multiline_urls_split.patch > > > The error is in the length parameter at > https://github.com/apache/trafficserver/blob/413dd51d5dc17bf388805071efdb8f882014b847/iocore/cache/CachePages.cc#L129 > Because of this error, ink_strlcpy copies strings from the current poisition > to the end of multiline URLs, not to the end of line. > The attached patch cache_inspector_multiline_urls_split.patch fixes this bug. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15104168#comment-15104168 ] ASF subversion and git services commented on TS-4140: - Commit 507dbaf62e3109495fb6aab1938e1b1d7d908ba3 in trafficserver's branch refs/heads/6.1.x from [~zwoop] [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=507dbaf ] TS-4140 Fixes a coverity warning due to changes in TS-4106 (dead code) This closes #427. > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. > {code} > *** CID 1348541: Control flow issues (DEADCODE) > /iocore/cache/CachePages.cc: 129 in ShowCache::ShowCache(Continuation *, > HTTPHdr *)() > 123 t = (char *)unescapedQuery + strlen(unescapedQuery); > 124 for (int s = 0; p < t; s++) { > 125 show_cache_urlstrs[s][0] = '\0'; > 126 q = strstr(p, "%0D%0A" /* \r\n */); // we used this in the > JS to separate urls > 127 if (!q) > 128 q = t; >CID 1348541: Control flow issues (DEADCODE) >Execution cannot reach the expression "500UL" inside this statement: > "ink_strlcpy(this->show_cach...". > 129 ink_strlcpy(show_cache_urlstrs[s], p, q ? q - p + 1 : > sizeof(show_cache_urlstrs[s])); > 130 p = q + 6; // +6 ==> strlen(%0D%0A) > 131 } > 132 } > 133 > 134 Debug("cache_inspector", "there were %d url(s) passed in", > nstrings == 1 ? 1 : nstrings - 1); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4141) CID 1348540: Null pointer dereferences
[ https://issues.apache.org/jira/browse/TS-4141?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4141: -- Assignee: Susan Hinrichs > CID 1348540: Null pointer dereferences > --- > > Key: TS-4141 > URL: https://issues.apache.org/jira/browse/TS-4141 > Project: Traffic Server > Issue Type: Bug > Components: HTTP >Reporter: Leif Hedstrom >Assignee: Susan Hinrichs > Labels: coverity > Fix For: 6.1.0 > > > {code} > *** CID 1348540: Null pointer dereferences (FORWARD_NULL) > /proxy/http/HttpSM.cc: 5643 in > HttpSM::attach_server_session(HttpServerSession *)() > 5637 server_entry->vc_handler = > ::state_send_server_request_header; > 5638 > 5639 > 5640 // es - is this a concern here in HttpSM? Does it belong > somewhere else? > 5641 // Get server and client connections > 5642 UnixNetVConnection *server_vc = dynamic_cast *>(server_session->get_netvc()); >CID 1348540: Null pointer dereferences (FORWARD_NULL) >Passing null pointer "this->ua_session" to "get_netvc", which dereferences > it. (The dereference happens because this is a virtual function call.) > 5643 UnixNetVConnection *client_vc = (UnixNetVConnection > *)(ua_session->get_netvc()); > 5644 SSLNetVConnection *ssl_vc = dynamic_cast *>(client_vc); > 5645 bool associated_connection = false; > 5646 if (server_vc) { // if server_vc isn't a PluginVC > 5647 if (ssl_vc) { // if incoming connection is SSL > 5648 bool client_trace = ssl_vc->getSSLTrace(); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4141) CID 1348540: Null pointer dereferences
[ https://issues.apache.org/jira/browse/TS-4141?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15104167#comment-15104167 ] ASF subversion and git services commented on TS-4141: - Commit 9381f6f889961adc7fddbea2a796440a975a5bae in trafficserver's branch refs/heads/6.1.x from shinrich [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=9381f6f ] TS-4141: Null check fix. (cherry picked from commit 56109f1c1dbde685cea35051f242d6f7e1c9821c) > CID 1348540: Null pointer dereferences > --- > > Key: TS-4141 > URL: https://issues.apache.org/jira/browse/TS-4141 > Project: Traffic Server > Issue Type: Bug > Components: HTTP >Reporter: Leif Hedstrom >Assignee: Susan Hinrichs > Labels: coverity > Fix For: 6.1.0 > > > {code} > *** CID 1348540: Null pointer dereferences (FORWARD_NULL) > /proxy/http/HttpSM.cc: 5643 in > HttpSM::attach_server_session(HttpServerSession *)() > 5637 server_entry->vc_handler = > ::state_send_server_request_header; > 5638 > 5639 > 5640 // es - is this a concern here in HttpSM? Does it belong > somewhere else? > 5641 // Get server and client connections > 5642 UnixNetVConnection *server_vc = dynamic_cast *>(server_session->get_netvc()); >CID 1348540: Null pointer dereferences (FORWARD_NULL) >Passing null pointer "this->ua_session" to "get_netvc", which dereferences > it. (The dereference happens because this is a virtual function call.) > 5643 UnixNetVConnection *client_vc = (UnixNetVConnection > *)(ua_session->get_netvc()); > 5644 SSLNetVConnection *ssl_vc = dynamic_cast *>(client_vc); > 5645 bool associated_connection = false; > 5646 if (server_vc) { // if server_vc isn't a PluginVC > 5647 if (ssl_vc) { // if incoming connection is SSL > 5648 bool client_trace = ssl_vc->getSSLTrace(); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Resolved] (TS-4141) CID 1348540: Null pointer dereferences
[ https://issues.apache.org/jira/browse/TS-4141?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom resolved TS-4141. --- Resolution: Fixed > CID 1348540: Null pointer dereferences > --- > > Key: TS-4141 > URL: https://issues.apache.org/jira/browse/TS-4141 > Project: Traffic Server > Issue Type: Bug > Components: HTTP >Reporter: Leif Hedstrom >Assignee: Susan Hinrichs > Labels: coverity > Fix For: 6.1.0 > > > {code} > *** CID 1348540: Null pointer dereferences (FORWARD_NULL) > /proxy/http/HttpSM.cc: 5643 in > HttpSM::attach_server_session(HttpServerSession *)() > 5637 server_entry->vc_handler = > ::state_send_server_request_header; > 5638 > 5639 > 5640 // es - is this a concern here in HttpSM? Does it belong > somewhere else? > 5641 // Get server and client connections > 5642 UnixNetVConnection *server_vc = dynamic_cast *>(server_session->get_netvc()); >CID 1348540: Null pointer dereferences (FORWARD_NULL) >Passing null pointer "this->ua_session" to "get_netvc", which dereferences > it. (The dereference happens because this is a virtual function call.) > 5643 UnixNetVConnection *client_vc = (UnixNetVConnection > *)(ua_session->get_netvc()); > 5644 SSLNetVConnection *ssl_vc = dynamic_cast *>(client_vc); > 5645 bool associated_connection = false; > 5646 if (server_vc) { // if server_vc isn't a PluginVC > 5647 if (ssl_vc) { // if incoming connection is SSL > 5648 bool client_trace = ssl_vc->getSSLTrace(); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4099) replace XML statistics with Lua
[ https://issues.apache.org/jira/browse/TS-4099?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15104108#comment-15104108 ] ASF GitHub Bot commented on TS-4099: Github user shukitchan commented on a diff in the pull request: https://github.com/apache/trafficserver/pull/422#discussion_r49959792 --- Diff: cmd/traffic_manager/metrics.cc --- @@ -0,0 +1,385 @@ +/** @file + * + * Traffic Manager custom metrics. + * + * @section license License + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include "ts/ink_config.h" +#include "ts/ink_memory.h" +#include "ts/Ptr.h" +#include "ts/Vec.h" +#include "ts/I_Layout.h" +#include "bindings/bindings.h" +#include "bindings/metrics.h" +#include "I_RecCore.h" +#include "MgmtDefs.h" +#include "MgmtUtils.h" +#include "WebOverview.h" +#include "metrics.h" + +struct Evaluator { + Evaluator() : rec_name(NULL), data_type(RECD_NULL), ref(-1) {} + + ~Evaluator() + { +ats_free(this->rec_name); +ink_release_assert(this->ref == -1); + } + + bool + bind(lua_State *L, const char *metric, const char *expression) + { +if (RecGetRecordDataType(metric, >data_type) != REC_ERR_OKAY) { + return false; +} + +this->rec_name = ats_strdup(metric); + +switch (luaL_loadstring(L, expression)) { +case LUA_ERRSYNTAX: +case LUA_ERRMEM: + Debug("lua", "loadstring failed for %s", metric); + luaL_error(L, "invalid expression for %s", metric); + return false; +case 0: + break; // success +} + +// The loaded chunk is now on the top of the stack. Stuff it into the registry +// so we can evaluate it later. +this->ref = luaL_ref(L, LUA_REGISTRYINDEX); + +return true; + } + + void + eval(lua_State *L) const + { +// Push the stashed expression chunk onto the stack. +lua_rawgeti(L, LUA_REGISTRYINDEX, this->ref); + +// Evaluate it. Note that we don't emit a warning for +// evaluation errors. This is because not all metrics (eg. +// cache metrics) are available early in startup so we don't +// want to log spurious warning. Unfortunately it means that +// to check your config for errors you need to enable +// diagnostic tags. +lua_pushstring(L, this->rec_name); +if (lua_pcall(L, 1 /* nargs */, 1 /* nresults */, 0) != 0) { + Debug("lua", "failed to evaluate %s: %s", this->rec_name, lua_tostring(L, -1)); + lua_pop(L, 1); + return; +} + +// If we got a return value, set it on the record. Records can return nil to +// indicate they don't want to be set on this round. +if (!lua_isnil(L, -1)) { + RecData rec_value; + + switch (this->data_type) { + case RECD_INT: +rec_value.rec_int = lua_tointeger(L, -1); +break; + case RECD_COUNTER: +rec_value.rec_counter = lua_tointeger(L, -1); +break; + case RECD_FLOAT: +// Lua will eval 0/0 to NaN rather than 0. +rec_value.rec_float = lua_tonumber(L, -1); +if (isnan(rec_value.rec_float)) { + rec_value.rec_float = 0.0; +} +break; + default: +goto done; + } + + RecSetRecord(RECT_NULL, this->rec_name, this->data_type, _value, NULL, REC_SOURCE_EXPLICIT); +} + + done: +// Pop the return value. +lua_pop(L, 1); + } + +private: + char *rec_name; + RecDataT data_type; + + int ref; +}; + +struct EvaluatorList { + EvaluatorList() : update(true), passes(0) {} + ~EvaluatorList() + { +forv_Vec(Evaluator, e, this->evaluators) { delete e; } + } + + void + push_back(Evaluator *e) +
[jira] [Resolved] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom resolved TS-4140. --- Resolution: Fixed > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. > {code} > *** CID 1348541: Control flow issues (DEADCODE) > /iocore/cache/CachePages.cc: 129 in ShowCache::ShowCache(Continuation *, > HTTPHdr *)() > 123 t = (char *)unescapedQuery + strlen(unescapedQuery); > 124 for (int s = 0; p < t; s++) { > 125 show_cache_urlstrs[s][0] = '\0'; > 126 q = strstr(p, "%0D%0A" /* \r\n */); // we used this in the > JS to separate urls > 127 if (!q) > 128 q = t; >CID 1348541: Control flow issues (DEADCODE) >Execution cannot reach the expression "500UL" inside this statement: > "ink_strlcpy(this->show_cach...". > 129 ink_strlcpy(show_cache_urlstrs[s], p, q ? q - p + 1 : > sizeof(show_cache_urlstrs[s])); > 130 p = q + 6; // +6 ==> strlen(%0D%0A) > 131 } > 132 } > 133 > 134 Debug("cache_inspector", "there were %d url(s) passed in", > nstrings == 1 ? 1 : nstrings - 1); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Resolved] (TS-4142) Compile errors on OmniOS
[ https://issues.apache.org/jira/browse/TS-4142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom resolved TS-4142. --- Resolution: Fixed > Compile errors on OmniOS > > > Key: TS-4142 > URL: https://issues.apache.org/jira/browse/TS-4142 > Project: Traffic Server > Issue Type: Bug > Components: Build >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: regresion > Fix For: 6.1.0 > > > There are a few additions / regressions causing OmniOS to not build. Most of > these need to be cherry-picked to 6.1.x, but some should not. So I'll break > this up into multiple commits for easy cherry picking. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4142) Compile errors on OmniOS
[ https://issues.apache.org/jira/browse/TS-4142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15104164#comment-15104164 ] ASF subversion and git services commented on TS-4142: - Commit a98e59383b0d5cfbbef7b3d4b50cceb93670b695 in trafficserver's branch refs/heads/6.1.x from [~zwoop] [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=a98e593 ] TS-4142: various casting fixes for OmniOS This closes #428. (cherry picked from commit 42534a43afb8950beec2df0d902b70af265dee97) > Compile errors on OmniOS > > > Key: TS-4142 > URL: https://issues.apache.org/jira/browse/TS-4142 > Project: Traffic Server > Issue Type: Bug > Components: Build >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: regresion > Fix For: 6.1.0 > > > There are a few additions / regressions causing OmniOS to not build. Most of > these need to be cherry-picked to 6.1.x, but some should not. So I'll break > this up into multiple commits for easy cherry picking. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4140: -- Labels: coverity (was: ) > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Assigned] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom reassigned TS-4140: - Assignee: Leif Hedstrom > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Created] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
Leif Hedstrom created TS-4140: - Summary: CID 1348541: Control flow issues (DEADCODE) Key: TS-4140 URL: https://issues.apache.org/jira/browse/TS-4140 Project: Traffic Server Issue Type: Bug Components: Web UI Reporter: Leif Hedstrom This is due to TS-4106, and I believe coverity is correct; q can't be NULL. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4141) CID 1348540: Null pointer dereferences
[ https://issues.apache.org/jira/browse/TS-4141?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4141: -- Labels: coverity (was: ) > CID 1348540: Null pointer dereferences > --- > > Key: TS-4141 > URL: https://issues.apache.org/jira/browse/TS-4141 > Project: Traffic Server > Issue Type: Bug > Components: HTTP >Reporter: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > {code} > *** CID 1348540: Null pointer dereferences (FORWARD_NULL) > /proxy/http/HttpSM.cc: 5643 in > HttpSM::attach_server_session(HttpServerSession *)() > 5637 server_entry->vc_handler = > ::state_send_server_request_header; > 5638 > 5639 > 5640 // es - is this a concern here in HttpSM? Does it belong > somewhere else? > 5641 // Get server and client connections > 5642 UnixNetVConnection *server_vc = dynamic_cast *>(server_session->get_netvc()); >CID 1348540: Null pointer dereferences (FORWARD_NULL) >Passing null pointer "this->ua_session" to "get_netvc", which dereferences > it. (The dereference happens because this is a virtual function call.) > 5643 UnixNetVConnection *client_vc = (UnixNetVConnection > *)(ua_session->get_netvc()); > 5644 SSLNetVConnection *ssl_vc = dynamic_cast *>(client_vc); > 5645 bool associated_connection = false; > 5646 if (server_vc) { // if server_vc isn't a PluginVC > 5647 if (ssl_vc) { // if incoming connection is SSL > 5648 bool client_trace = ssl_vc->getSSLTrace(); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4141) CID 1348540: Null pointer dereferences
[ https://issues.apache.org/jira/browse/TS-4141?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4141: -- Fix Version/s: 6.1.0 > CID 1348540: Null pointer dereferences > --- > > Key: TS-4141 > URL: https://issues.apache.org/jira/browse/TS-4141 > Project: Traffic Server > Issue Type: Bug > Components: HTTP >Reporter: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > {code} > *** CID 1348540: Null pointer dereferences (FORWARD_NULL) > /proxy/http/HttpSM.cc: 5643 in > HttpSM::attach_server_session(HttpServerSession *)() > 5637 server_entry->vc_handler = > ::state_send_server_request_header; > 5638 > 5639 > 5640 // es - is this a concern here in HttpSM? Does it belong > somewhere else? > 5641 // Get server and client connections > 5642 UnixNetVConnection *server_vc = dynamic_cast *>(server_session->get_netvc()); >CID 1348540: Null pointer dereferences (FORWARD_NULL) >Passing null pointer "this->ua_session" to "get_netvc", which dereferences > it. (The dereference happens because this is a virtual function call.) > 5643 UnixNetVConnection *client_vc = (UnixNetVConnection > *)(ua_session->get_netvc()); > 5644 SSLNetVConnection *ssl_vc = dynamic_cast *>(client_vc); > 5645 bool associated_connection = false; > 5646 if (server_vc) { // if server_vc isn't a PluginVC > 5647 if (ssl_vc) { // if incoming connection is SSL > 5648 bool client_trace = ssl_vc->getSSLTrace(); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4140: -- Fix Version/s: 6.1.0 > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-3922) Add independent WebSocket timeouts
[ https://issues.apache.org/jira/browse/TS-3922?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-3922: -- Fix Version/s: 6.2.0 > Add independent WebSocket timeouts > -- > > Key: TS-3922 > URL: https://issues.apache.org/jira/browse/TS-3922 > Project: Traffic Server > Issue Type: Improvement > Components: Core >Reporter: Brian Geffon >Assignee: Brian Geffon > Fix For: 6.2.0 > > > Right now WebSockets fall under the active/inactive transaction timeouts. > Obviously the inactivate timeout isn't a problem but the active timeout is. > We need at minimum a new timeout for active WS connections, I'll likely add a > new timeout for inactive state too. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Assigned] (TS-4142) Compile errors on OmniOS
[ https://issues.apache.org/jira/browse/TS-4142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom reassigned TS-4142: - Assignee: Leif Hedstrom > Compile errors on OmniOS > > > Key: TS-4142 > URL: https://issues.apache.org/jira/browse/TS-4142 > Project: Traffic Server > Issue Type: Bug > Components: Build >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: regresion > Fix For: 6.1.0 > > > There are a few additions / regressions causing OmniOS to not build. Most of > these need to be cherry-picked to 6.1.x, but some should not. So I'll break > this up into multiple commits for easy cherry picking. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Created] (TS-4142) Compile errors on OmniOS
Leif Hedstrom created TS-4142: - Summary: Compile errors on OmniOS Key: TS-4142 URL: https://issues.apache.org/jira/browse/TS-4142 Project: Traffic Server Issue Type: Bug Components: Build Reporter: Leif Hedstrom There are a few additions / regressions causing OmniOS to not build. Most of these need to be cherry-picked to 6.1.x, but some should not. So I'll break this up into multiple commits for easy cherry picking. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4131) InactivityCop broken the VC_EVENT_ACTIVE_TIMEOUT
[ https://issues.apache.org/jira/browse/TS-4131?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4131: -- Labels: regresion (was: ) > InactivityCop broken the VC_EVENT_ACTIVE_TIMEOUT > > > Key: TS-4131 > URL: https://issues.apache.org/jira/browse/TS-4131 > Project: Traffic Server > Issue Type: Bug > Components: Core >Reporter: Oknet Xu > Labels: regresion > > relative code below: > {code} > int > UnixNetVConnection::mainEvent(int event, Event *e) > { > ink_assert(event == EVENT_IMMEDIATE || event == EVENT_INTERVAL); > ink_assert(thread == this_ethread()); > ... > #ifdef INACTIVITY_TIMEOUT > if (e == inactivity_timeout) { > signal_event = VC_EVENT_INACTIVITY_TIMEOUT; > signal_timeout = _timeout; > } else { > ink_assert(e == active_timeout); > signal_event = VC_EVENT_ACTIVE_TIMEOUT; > signal_timeout = _timeout; > } > #else > if (event == EVENT_IMMEDIATE) { > /* BZ 49408 */ > // ink_assert(inactivity_timeout_in); > // ink_assert(next_inactivity_timeout_at < ink_get_hrtime()); > if (!inactivity_timeout_in || next_inactivity_timeout_at > > Thread::get_hrtime()) > return EVENT_CONT; > signal_event = VC_EVENT_INACTIVITY_TIMEOUT; > signal_timeout_at = _inactivity_timeout_at; > } else { > signal_event = VC_EVENT_ACTIVE_TIMEOUT; > signal_timeout_at = _activity_timeout_at; > } > #endif > {code} > To enable InactiveCop, the INACTIVITY_TIMEOUT is not defined. > an event == EVENT_INTERVAL callback means VC_EVENT_ACTIVE_TIMEOUT. > but there are only EVENT_IMMEDIATE callbacked from InactiveCop. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4132) Open source Yahoo's ats-inliner plug-in
[ https://issues.apache.org/jira/browse/TS-4132?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4132: -- Fix Version/s: 6.2.0 > Open source Yahoo's ats-inliner plug-in > --- > > Key: TS-4132 > URL: https://issues.apache.org/jira/browse/TS-4132 > Project: Traffic Server > Issue Type: New Feature > Components: Plugins >Reporter: Daniel Vitor Morilha > Fix For: 6.2.0 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4132) Open source Yahoo's ats-inliner plug-in
[ https://issues.apache.org/jira/browse/TS-4132?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4132: -- Component/s: Plugins > Open source Yahoo's ats-inliner plug-in > --- > > Key: TS-4132 > URL: https://issues.apache.org/jira/browse/TS-4132 > Project: Traffic Server > Issue Type: New Feature > Components: Plugins >Reporter: Daniel Vitor Morilha > Fix For: 6.2.0 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4133) Update url_sig plugin to pass application query parameters
[ https://issues.apache.org/jira/browse/TS-4133?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4133: -- Fix Version/s: 6.2.0 > Update url_sig plugin to pass application query parameters > -- > > Key: TS-4133 > URL: https://issues.apache.org/jira/browse/TS-4133 > Project: Traffic Server > Issue Type: Improvement > Components: Plugins >Reporter: John Rushford >Assignee: John Rushford > Fix For: 6.2.0 > > > Currently the url_sig plugin assumes that request urls have no other query > parameters but url signing related parameters. After signing validation is > performed using the signing parameters all query parameters are stripped from > the request. > This change will allow application query parameters that must be sent to the > origin to fulfill a request to be left intact in the request. When signing a > request with application query parameters it is required that the url signing > parameters used by this plugin must come after the application parameters. > When the request comes in the plugin will truncate the url signing parameters > after verification leaving the application parameters intact. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103921#comment-15103921 ] ASF GitHub Bot commented on TS-4140: GitHub user zwoop opened a pull request: https://github.com/apache/trafficserver/pull/427 TS-4140 Fixes a coverity warning due to changes in TS-4106 (dead code) This restores an older behavior, removing an unnecessary conditional (dead code).q can never be NUL.. You can merge this pull request into a Git repository by running: $ git pull https://github.com/zwoop/trafficserver TS-4140 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/trafficserver/pull/427.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #427 commit bacda9914fdfe4acd9e8f01e1fffb6d3f2773f65 Author: Leif HedstromDate: 2016-01-17T20:55:24Z TS-4140 Fixes a coverity warning due to changes in TS-4106 (dead code) > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4140: -- Description: This is due to TS-4106, and I believe coverity is correct; q can't be NULL. {code} *** CID 1348541: Control flow issues (DEADCODE) /iocore/cache/CachePages.cc: 129 in ShowCache::ShowCache(Continuation *, HTTPHdr *)() 123 t = (char *)unescapedQuery + strlen(unescapedQuery); 124 for (int s = 0; p < t; s++) { 125 show_cache_urlstrs[s][0] = '\0'; 126 q = strstr(p, "%0D%0A" /* \r\n */); // we used this in the JS to separate urls 127 if (!q) 128 q = t; CID 1348541: Control flow issues (DEADCODE) Execution cannot reach the expression "500UL" inside this statement: "ink_strlcpy(this->show_cach...". 129 ink_strlcpy(show_cache_urlstrs[s], p, q ? q - p + 1 : sizeof(show_cache_urlstrs[s])); 130 p = q + 6; // +6 ==> strlen(%0D%0A) 131 } 132 } 133 134 Debug("cache_inspector", "there were %d url(s) passed in", nstrings == 1 ? 1 : nstrings - 1); {code} was:This is due to TS-4106, and I believe coverity is correct; q can't be NULL. > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. > {code} > *** CID 1348541: Control flow issues (DEADCODE) > /iocore/cache/CachePages.cc: 129 in ShowCache::ShowCache(Continuation *, > HTTPHdr *)() > 123 t = (char *)unescapedQuery + strlen(unescapedQuery); > 124 for (int s = 0; p < t; s++) { > 125 show_cache_urlstrs[s][0] = '\0'; > 126 q = strstr(p, "%0D%0A" /* \r\n */); // we used this in the > JS to separate urls > 127 if (!q) > 128 q = t; >CID 1348541: Control flow issues (DEADCODE) >Execution cannot reach the expression "500UL" inside this statement: > "ink_strlcpy(this->show_cach...". > 129 ink_strlcpy(show_cache_urlstrs[s], p, q ? q - p + 1 : > sizeof(show_cache_urlstrs[s])); > 130 p = q + 6; // +6 ==> strlen(%0D%0A) > 131 } > 132 } > 133 > 134 Debug("cache_inspector", "there were %d url(s) passed in", > nstrings == 1 ? 1 : nstrings - 1); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Created] (TS-4141) CID 1348540: Null pointer dereferences
Leif Hedstrom created TS-4141: - Summary: CID 1348540: Null pointer dereferences Key: TS-4141 URL: https://issues.apache.org/jira/browse/TS-4141 Project: Traffic Server Issue Type: Bug Components: HTTP Reporter: Leif Hedstrom {code} *** CID 1348540: Null pointer dereferences (FORWARD_NULL) /proxy/http/HttpSM.cc: 5643 in HttpSM::attach_server_session(HttpServerSession *)() 5637 server_entry->vc_handler = ::state_send_server_request_header; 5638 5639 5640 // es - is this a concern here in HttpSM? Does it belong somewhere else? 5641 // Get server and client connections 5642 UnixNetVConnection *server_vc = dynamic_cast(server_session->get_netvc()); CID 1348540: Null pointer dereferences (FORWARD_NULL) Passing null pointer "this->ua_session" to "get_netvc", which dereferences it. (The dereference happens because this is a virtual function call.) 5643 UnixNetVConnection *client_vc = (UnixNetVConnection *)(ua_session->get_netvc()); 5644 SSLNetVConnection *ssl_vc = dynamic_cast(client_vc); 5645 bool associated_connection = false; 5646 if (server_vc) { // if server_vc isn't a PluginVC 5647 if (ssl_vc) { // if incoming connection is SSL 5648 bool client_trace = ssl_vc->getSSLTrace(); {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4139) CID 1348542: Unchecked return value in Http2ConnectionState
[ https://issues.apache.org/jira/browse/TS-4139?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103912#comment-15103912 ] ASF subversion and git services commented on TS-4139: - Commit 9ca988a2d9d12d8595375e6f2ca76f35dcc1ff4e in trafficserver's branch refs/heads/6.1.x from [~maskit] [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=9ca988a ] TS-4139: Send GOAWAY if it failed to change stream state This is a fix for CID 1347871: Unchecked return value This closes #426 (cherry picked from commit 925b9c17a832c6800571a1bf13689d4e4efef35c) > CID 1348542: Unchecked return value in Http2ConnectionState > --- > > Key: TS-4139 > URL: https://issues.apache.org/jira/browse/TS-4139 > Project: Traffic Server > Issue Type: Bug >Reporter: Masakazu Kitajo >Assignee: Masakazu Kitajo > Labels: coverity > Fix For: 6.1.0 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Resolved] (TS-4139) CID 1348542: Unchecked return value in Http2ConnectionState
[ https://issues.apache.org/jira/browse/TS-4139?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom resolved TS-4139. --- Resolution: Fixed > CID 1348542: Unchecked return value in Http2ConnectionState > --- > > Key: TS-4139 > URL: https://issues.apache.org/jira/browse/TS-4139 > Project: Traffic Server > Issue Type: Bug >Reporter: Masakazu Kitajo >Assignee: Masakazu Kitajo > Labels: coverity > Fix For: 6.1.0 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4139) CID 1348542: Unchecked return value in Http2ConnectionState
[ https://issues.apache.org/jira/browse/TS-4139?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103911#comment-15103911 ] ASF GitHub Bot commented on TS-4139: Github user asfgit closed the pull request at: https://github.com/apache/trafficserver/pull/426 > CID 1348542: Unchecked return value in Http2ConnectionState > --- > > Key: TS-4139 > URL: https://issues.apache.org/jira/browse/TS-4139 > Project: Traffic Server > Issue Type: Bug >Reporter: Masakazu Kitajo >Assignee: Masakazu Kitajo > Labels: coverity > Fix For: 6.1.0 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4139) CID 1348542: Unchecked return value in Http2ConnectionState
[ https://issues.apache.org/jira/browse/TS-4139?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103910#comment-15103910 ] ASF subversion and git services commented on TS-4139: - Commit 925b9c17a832c6800571a1bf13689d4e4efef35c in trafficserver's branch refs/heads/master from [~maskit] [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=925b9c1 ] TS-4139: Send GOAWAY if it failed to change stream state This is a fix for CID 1347871: Unchecked return value This closes #426 > CID 1348542: Unchecked return value in Http2ConnectionState > --- > > Key: TS-4139 > URL: https://issues.apache.org/jira/browse/TS-4139 > Project: Traffic Server > Issue Type: Bug >Reporter: Masakazu Kitajo >Assignee: Masakazu Kitajo > Labels: coverity > Fix For: 6.1.0 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4141) CID 1348540: Null pointer dereferences
[ https://issues.apache.org/jira/browse/TS-4141?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103922#comment-15103922 ] Leif Hedstrom commented on TS-4141: --- Can someone please help assess if this is an issue that must go in for 6.1.0 RC1 ? > CID 1348540: Null pointer dereferences > --- > > Key: TS-4141 > URL: https://issues.apache.org/jira/browse/TS-4141 > Project: Traffic Server > Issue Type: Bug > Components: HTTP >Reporter: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > {code} > *** CID 1348540: Null pointer dereferences (FORWARD_NULL) > /proxy/http/HttpSM.cc: 5643 in > HttpSM::attach_server_session(HttpServerSession *)() > 5637 server_entry->vc_handler = > ::state_send_server_request_header; > 5638 > 5639 > 5640 // es - is this a concern here in HttpSM? Does it belong > somewhere else? > 5641 // Get server and client connections > 5642 UnixNetVConnection *server_vc = dynamic_cast *>(server_session->get_netvc()); >CID 1348540: Null pointer dereferences (FORWARD_NULL) >Passing null pointer "this->ua_session" to "get_netvc", which dereferences > it. (The dereference happens because this is a virtual function call.) > 5643 UnixNetVConnection *client_vc = (UnixNetVConnection > *)(ua_session->get_netvc()); > 5644 SSLNetVConnection *ssl_vc = dynamic_cast *>(client_vc); > 5645 bool associated_connection = false; > 5646 if (server_vc) { // if server_vc isn't a PluginVC > 5647 if (ssl_vc) { // if incoming connection is SSL > 5648 bool client_trace = ssl_vc->getSSLTrace(); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4142) Compile errors on OmniOS
[ https://issues.apache.org/jira/browse/TS-4142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4142: -- Labels: regresion (was: ) > Compile errors on OmniOS > > > Key: TS-4142 > URL: https://issues.apache.org/jira/browse/TS-4142 > Project: Traffic Server > Issue Type: Bug > Components: Build >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: regresion > Fix For: 6.1.0 > > > There are a few additions / regressions causing OmniOS to not build. Most of > these need to be cherry-picked to 6.1.x, but some should not. So I'll break > this up into multiple commits for easy cherry picking. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4142) Compile errors on OmniOS
[ https://issues.apache.org/jira/browse/TS-4142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Leif Hedstrom updated TS-4142: -- Fix Version/s: 6.1.0 > Compile errors on OmniOS > > > Key: TS-4142 > URL: https://issues.apache.org/jira/browse/TS-4142 > Project: Traffic Server > Issue Type: Bug > Components: Build >Reporter: Leif Hedstrom > Labels: regresion > Fix For: 6.1.0 > > > There are a few additions / regressions causing OmniOS to not build. Most of > these need to be cherry-picked to 6.1.x, but some should not. So I'll break > this up into multiple commits for easy cherry picking. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4106) Cache Inspector fails to split multiline URLs
[ https://issues.apache.org/jira/browse/TS-4106?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103982#comment-15103982 ] ASF subversion and git services commented on TS-4106: - Commit 7115b366b5e2946960175a596daf1b5374443876 in trafficserver's branch refs/heads/master from [~zwoop] [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=7115b36 ] TS-4140 Fixes a coverity warning due to changes in TS-4106 (dead code) This closes #427. > Cache Inspector fails to split multiline URLs > - > > Key: TS-4106 > URL: https://issues.apache.org/jira/browse/TS-4106 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Hiroaki Nakamura >Assignee: Leif Hedstrom > Fix For: 6.1.0 > > Attachments: cache_inspector_multiline_urls_split.patch > > > The error is in the length parameter at > https://github.com/apache/trafficserver/blob/413dd51d5dc17bf388805071efdb8f882014b847/iocore/cache/CachePages.cc#L129 > Because of this error, ink_strlcpy copies strings from the current poisition > to the end of multiline URLs, not to the end of line. > The attached patch cache_inspector_multiline_urls_split.patch fixes this bug. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103983#comment-15103983 ] ASF GitHub Bot commented on TS-4140: Github user asfgit closed the pull request at: https://github.com/apache/trafficserver/pull/427 > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. > {code} > *** CID 1348541: Control flow issues (DEADCODE) > /iocore/cache/CachePages.cc: 129 in ShowCache::ShowCache(Continuation *, > HTTPHdr *)() > 123 t = (char *)unescapedQuery + strlen(unescapedQuery); > 124 for (int s = 0; p < t; s++) { > 125 show_cache_urlstrs[s][0] = '\0'; > 126 q = strstr(p, "%0D%0A" /* \r\n */); // we used this in the > JS to separate urls > 127 if (!q) > 128 q = t; >CID 1348541: Control flow issues (DEADCODE) >Execution cannot reach the expression "500UL" inside this statement: > "ink_strlcpy(this->show_cach...". > 129 ink_strlcpy(show_cache_urlstrs[s], p, q ? q - p + 1 : > sizeof(show_cache_urlstrs[s])); > 130 p = q + 6; // +6 ==> strlen(%0D%0A) > 131 } > 132 } > 133 > 134 Debug("cache_inspector", "there were %d url(s) passed in", > nstrings == 1 ? 1 : nstrings - 1); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103981#comment-15103981 ] ASF subversion and git services commented on TS-4140: - Commit 7115b366b5e2946960175a596daf1b5374443876 in trafficserver's branch refs/heads/master from [~zwoop] [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=7115b36 ] TS-4140 Fixes a coverity warning due to changes in TS-4106 (dead code) This closes #427. > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. > {code} > *** CID 1348541: Control flow issues (DEADCODE) > /iocore/cache/CachePages.cc: 129 in ShowCache::ShowCache(Continuation *, > HTTPHdr *)() > 123 t = (char *)unescapedQuery + strlen(unescapedQuery); > 124 for (int s = 0; p < t; s++) { > 125 show_cache_urlstrs[s][0] = '\0'; > 126 q = strstr(p, "%0D%0A" /* \r\n */); // we used this in the > JS to separate urls > 127 if (!q) > 128 q = t; >CID 1348541: Control flow issues (DEADCODE) >Execution cannot reach the expression "500UL" inside this statement: > "ink_strlcpy(this->show_cach...". > 129 ink_strlcpy(show_cache_urlstrs[s], p, q ? q - p + 1 : > sizeof(show_cache_urlstrs[s])); > 130 p = q + 6; // +6 ==> strlen(%0D%0A) > 131 } > 132 } > 133 > 134 Debug("cache_inspector", "there were %d url(s) passed in", > nstrings == 1 ? 1 : nstrings - 1); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4140) CID 1348541: Control flow issues (DEADCODE)
[ https://issues.apache.org/jira/browse/TS-4140?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103977#comment-15103977 ] ASF GitHub Bot commented on TS-4140: Github user maskit commented on the pull request: https://github.com/apache/trafficserver/pull/427#issuecomment-172394940 Looks good to me. > CID 1348541: Control flow issues (DEADCODE) > - > > Key: TS-4140 > URL: https://issues.apache.org/jira/browse/TS-4140 > Project: Traffic Server > Issue Type: Bug > Components: Web UI >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > This is due to TS-4106, and I believe coverity is correct; q can't be NULL. > {code} > *** CID 1348541: Control flow issues (DEADCODE) > /iocore/cache/CachePages.cc: 129 in ShowCache::ShowCache(Continuation *, > HTTPHdr *)() > 123 t = (char *)unescapedQuery + strlen(unescapedQuery); > 124 for (int s = 0; p < t; s++) { > 125 show_cache_urlstrs[s][0] = '\0'; > 126 q = strstr(p, "%0D%0A" /* \r\n */); // we used this in the > JS to separate urls > 127 if (!q) > 128 q = t; >CID 1348541: Control flow issues (DEADCODE) >Execution cannot reach the expression "500UL" inside this statement: > "ink_strlcpy(this->show_cach...". > 129 ink_strlcpy(show_cache_urlstrs[s], p, q ? q - p + 1 : > sizeof(show_cache_urlstrs[s])); > 130 p = q + 6; // +6 ==> strlen(%0D%0A) > 131 } > 132 } > 133 > 134 Debug("cache_inspector", "there were %d url(s) passed in", > nstrings == 1 ? 1 : nstrings - 1); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4142) Compile errors on OmniOS
[ https://issues.apache.org/jira/browse/TS-4142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103978#comment-15103978 ] ASF subversion and git services commented on TS-4142: - Commit 1ef6ff766c2cef8632e7b77d4a03aa378883ebc5 in trafficserver's branch refs/heads/master from [~zwoop] [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=1ef6ff7 ] TS-4142: use uint32_t in preference to non-standard u_int32_t This closes #428. > Compile errors on OmniOS > > > Key: TS-4142 > URL: https://issues.apache.org/jira/browse/TS-4142 > Project: Traffic Server > Issue Type: Bug > Components: Build >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: regresion > Fix For: 6.1.0 > > > There are a few additions / regressions causing OmniOS to not build. Most of > these need to be cherry-picked to 6.1.x, but some should not. So I'll break > this up into multiple commits for easy cherry picking. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4142) Compile errors on OmniOS
[ https://issues.apache.org/jira/browse/TS-4142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103979#comment-15103979 ] ASF subversion and git services commented on TS-4142: - Commit 42534a43afb8950beec2df0d902b70af265dee97 in trafficserver's branch refs/heads/master from [~zwoop] [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=42534a4 ] TS-4142: various casting fixes for OmniOS This closes #428. > Compile errors on OmniOS > > > Key: TS-4142 > URL: https://issues.apache.org/jira/browse/TS-4142 > Project: Traffic Server > Issue Type: Bug > Components: Build >Reporter: Leif Hedstrom >Assignee: Leif Hedstrom > Labels: regresion > Fix For: 6.1.0 > > > There are a few additions / regressions causing OmniOS to not build. Most of > these need to be cherry-picked to 6.1.x, but some should not. So I'll break > this up into multiple commits for easy cherry picking. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4141) CID 1348540: Null pointer dereferences
[ https://issues.apache.org/jira/browse/TS-4141?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15104044#comment-15104044 ] ASF subversion and git services commented on TS-4141: - Commit 56109f1c1dbde685cea35051f242d6f7e1c9821c in trafficserver's branch refs/heads/master from shinrich [ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=56109f1 ] TS-4141: Null check fix. > CID 1348540: Null pointer dereferences > --- > > Key: TS-4141 > URL: https://issues.apache.org/jira/browse/TS-4141 > Project: Traffic Server > Issue Type: Bug > Components: HTTP >Reporter: Leif Hedstrom > Labels: coverity > Fix For: 6.1.0 > > > {code} > *** CID 1348540: Null pointer dereferences (FORWARD_NULL) > /proxy/http/HttpSM.cc: 5643 in > HttpSM::attach_server_session(HttpServerSession *)() > 5637 server_entry->vc_handler = > ::state_send_server_request_header; > 5638 > 5639 > 5640 // es - is this a concern here in HttpSM? Does it belong > somewhere else? > 5641 // Get server and client connections > 5642 UnixNetVConnection *server_vc = dynamic_cast *>(server_session->get_netvc()); >CID 1348540: Null pointer dereferences (FORWARD_NULL) >Passing null pointer "this->ua_session" to "get_netvc", which dereferences > it. (The dereference happens because this is a virtual function call.) > 5643 UnixNetVConnection *client_vc = (UnixNetVConnection > *)(ua_session->get_netvc()); > 5644 SSLNetVConnection *ssl_vc = dynamic_cast *>(client_vc); > 5645 bool associated_connection = false; > 5646 if (server_vc) { // if server_vc isn't a PluginVC > 5647 if (ssl_vc) { // if incoming connection is SSL > 5648 bool client_trace = ssl_vc->getSSLTrace(); > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Assigned] (TS-4139) CID 1348542: Unchecked return value in Http2ConnectionState
[ https://issues.apache.org/jira/browse/TS-4139?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Masakazu Kitajo reassigned TS-4139: --- Assignee: Masakazu Kitajo > CID 1348542: Unchecked return value in Http2ConnectionState > --- > > Key: TS-4139 > URL: https://issues.apache.org/jira/browse/TS-4139 > Project: Traffic Server > Issue Type: Bug >Reporter: Masakazu Kitajo >Assignee: Masakazu Kitajo > Labels: coverity > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4139) CID 1348542: Unchecked return value in Http2ConnectionState
[ https://issues.apache.org/jira/browse/TS-4139?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Masakazu Kitajo updated TS-4139: Labels: coverity (was: ) > CID 1348542: Unchecked return value in Http2ConnectionState > --- > > Key: TS-4139 > URL: https://issues.apache.org/jira/browse/TS-4139 > Project: Traffic Server > Issue Type: Bug >Reporter: Masakazu Kitajo > Labels: coverity > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (TS-4139) CID 1348542: Unchecked return value in Http2ConnectionState
[ https://issues.apache.org/jira/browse/TS-4139?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15103725#comment-15103725 ] ASF GitHub Bot commented on TS-4139: GitHub user maskit opened a pull request: https://github.com/apache/trafficserver/pull/426 TS-4139: Send GOAWAY if it failed to change stream state This is a fix for CID 1347871: Unchecked return value You can merge this pull request into a Git repository by running: $ git pull https://github.com/maskit/trafficserver ts4139 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/trafficserver/pull/426.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #426 commit fd1ca15a8e14f5d1eac93d445b45e6b43d9abbc4 Author: Masakazu KitajoDate: 2016-01-17T13:03:35Z TS-4139: Send GOAWAY if it failed to change stream state This is a fix for CID 1347871: Unchecked return value > CID 1348542: Unchecked return value in Http2ConnectionState > --- > > Key: TS-4139 > URL: https://issues.apache.org/jira/browse/TS-4139 > Project: Traffic Server > Issue Type: Bug >Reporter: Masakazu Kitajo >Assignee: Masakazu Kitajo > Labels: coverity > -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Updated] (TS-4139) CID 1348542: Unchecked return value in Http2ConnectionState
[ https://issues.apache.org/jira/browse/TS-4139?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Masakazu Kitajo updated TS-4139: Fix Version/s: 6.1.0 > CID 1348542: Unchecked return value in Http2ConnectionState > --- > > Key: TS-4139 > URL: https://issues.apache.org/jira/browse/TS-4139 > Project: Traffic Server > Issue Type: Bug >Reporter: Masakazu Kitajo >Assignee: Masakazu Kitajo > Labels: coverity > Fix For: 6.1.0 > > -- This message was sent by Atlassian JIRA (v6.3.4#6332)