|
|
Chromium Code Reviews
DescriptionDo not check ProxyInfo if the the DRP config is not valid
A previous CL (https://codereview.chromium.org/1702253002)
made a change and called result->proxy_server() without
checking if DRP config is valid. This caused Chrome
to crash because if config is not valid, calling result-
>proxy_server() may cause crashes (because there may not be
any proxy server in result).
This CL reverts back to behavior before that CL. Before
result->proxy_server() is called, it is ensured that the
DRP config must be valid.
BUG=591356
Committed: https://crrev.com/50eb58711b04bd731486974488e46546bf45b0bb
Cr-Commit-Position: refs/heads/master@{#379048}
Patch Set 1 #
Total comments: 2
Patch Set 2 : Simplified the logic #
Messages
Total messages: 22 (12 generated)
Description was changed from ========== w BUG= ========== to ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called methods of net::ProxyInfo without checking if DRP config is valid or not. This caused Chrome to crash because when config is not valid, calling result->proxy_server() may cause crashes. This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ==========
Description was changed from ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called methods of net::ProxyInfo without checking if DRP config is valid or not. This caused Chrome to crash because when config is not valid, calling result->proxy_server() may cause crashes. This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ========== to ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called methods of net::ProxyInfo without checking if DRP config is valid or not. This caused Chrome to crash because when config is not valid, calling result- >proxy_server() may cause crashes. This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ==========
Description was changed from ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called methods of net::ProxyInfo without checking if DRP config is valid or not. This caused Chrome to crash because when config is not valid, calling result- >proxy_server() may cause crashes. This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ========== to ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called result->proxy_server() without checking if DRP config is valid. This caused Chrome to crash because if config is not valid, calling result- >proxy_server() may cause crashes (because there may not be any proxy server in result). This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ==========
Description was changed from ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called result->proxy_server() without checking if DRP config is valid. This caused Chrome to crash because if config is not valid, calling result- >proxy_server() may cause crashes (because there may not be any proxy server in result). This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ========== to ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called result->proxy_server() without checking if DRP config is valid. This caused Chrome to crash because if config is not valid, calling result- >proxy_server() may cause crashes (because there may not be any proxy server in result). This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ==========
tbansal@chromium.org changed reviewers: + kundaji@chromium.org, ryansturm@chromium.org
kundaji, ryansturm: PTAL. Thanks!
https://codereview.chromium.org/1756323002/diff/1/components/data_reduction_p... File components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.cc (right): https://codereview.chromium.org/1756323002/diff/1/components/data_reduction_p... components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.cc:122: if (!data_reduction_proxy_config.is_valid() && It looks like you are recording UMA for the case of proxy_list.size() == 2, etc. Should this case be recorded? This is a case when lacking a config isn't the only thing preventing us from going out to the proxy server. I think you should in some form check if |result| is empty here if you want the UMA to record the cases where the config is the only thing at fault. I'd recommend changing the original "!result->proxy_server().is_direct()" to "!result->is_direct()" as this call will first check if |result| is empty before trying to get at the proxy_server.
ptal. thanks. https://codereview.chromium.org/1756323002/diff/1/components/data_reduction_p... File components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.cc (right): https://codereview.chromium.org/1756323002/diff/1/components/data_reduction_p... components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.cc:122: if (!data_reduction_proxy_config.is_valid() && On 2016/03/02 23:39:17, RyanSturm wrote: > It looks like you are recording UMA for the case of proxy_list.size() == 2, etc. > Should this case be recorded? This is a case when lacking a config isn't the > only thing preventing us from going out to the proxy server. > > I think you should in some form check if |result| is empty here if you want the > UMA to record the cases where the config is the only thing at fault. > > I'd recommend changing the original "!result->proxy_server().is_direct()" to > "!result->is_direct()" as this call will first check if |result| is empty before > trying to get at the proxy_server. Simplified the logic.
On 2016/03/03 00:03:19, tbansal1 wrote: > ptal. thanks. > > https://codereview.chromium.org/1756323002/diff/1/components/data_reduction_p... > File > components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.cc > (right): > > https://codereview.chromium.org/1756323002/diff/1/components/data_reduction_p... > components/data_reduction_proxy/core/browser/data_reduction_proxy_delegate.cc:122: > if (!data_reduction_proxy_config.is_valid() && > On 2016/03/02 23:39:17, RyanSturm wrote: > > It looks like you are recording UMA for the case of proxy_list.size() == 2, > etc. > > Should this case be recorded? This is a case when lacking a config isn't the > > only thing preventing us from going out to the proxy server. > > > > I think you should in some form check if |result| is empty here if you want > the > > UMA to record the cases where the config is the only thing at fault. > > > > I'd recommend changing the original "!result->proxy_server().is_direct()" to > > "!result->is_direct()" as this call will first check if |result| is empty > before > > trying to get at the proxy_server. > > Simplified the logic. lgtm
The CQ bit was checked by tbansal@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1756323002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1756323002/20001
The CQ bit was unchecked by tbansal@chromium.org
tbansal@chromium.org changed reviewers: + sclittle@chromium.org - kundaji@chromium.org
sclittle: ptal. thanks.
tbansal@chromium.org changed reviewers: + kundaji@chromium.org
lgtm
The CQ bit was checked by tbansal@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1756323002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1756323002/20001
Message was sent while issue was closed.
Description was changed from ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called result->proxy_server() without checking if DRP config is valid. This caused Chrome to crash because if config is not valid, calling result- >proxy_server() may cause crashes (because there may not be any proxy server in result). This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ========== to ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called result->proxy_server() without checking if DRP config is valid. This caused Chrome to crash because if config is not valid, calling result- >proxy_server() may cause crashes (because there may not be any proxy server in result). This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ==========
Message was sent while issue was closed.
Committed patchset #2 (id:20001)
Message was sent while issue was closed.
Description was changed from ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called result->proxy_server() without checking if DRP config is valid. This caused Chrome to crash because if config is not valid, calling result- >proxy_server() may cause crashes (because there may not be any proxy server in result). This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 ========== to ========== Do not check ProxyInfo if the the DRP config is not valid A previous CL (https://codereview.chromium.org/1702253002) made a change and called result->proxy_server() without checking if DRP config is valid. This caused Chrome to crash because if config is not valid, calling result- >proxy_server() may cause crashes (because there may not be any proxy server in result). This CL reverts back to behavior before that CL. Before result->proxy_server() is called, it is ensured that the DRP config must be valid. BUG=591356 Committed: https://crrev.com/50eb58711b04bd731486974488e46546bf45b0bb Cr-Commit-Position: refs/heads/master@{#379048} ==========
Message was sent while issue was closed.
Patchset 2 (id:??) landed as https://crrev.com/50eb58711b04bd731486974488e46546bf45b0bb Cr-Commit-Position: refs/heads/master@{#379048} |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
