Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(527)

Unified Diff: third_party/WebKit/Source/core/loader/PingLoader.cpp

Issue 2751953002: sendBeacon(): once transmission allowance has been reached, always fail. (Closed)
Patch Set: fix test description imprecision Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/sendbeacon/beacon-allowance-limit.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/loader/PingLoader.cpp
diff --git a/third_party/WebKit/Source/core/loader/PingLoader.cpp b/third_party/WebKit/Source/core/loader/PingLoader.cpp
index e9cddb9b2385cf0f7c36e00878fa6207edcae0d6..cb6542d3d1ef5c6aa7a6acf3adf6f3f74a49aef4 100644
--- a/third_party/WebKit/Source/core/loader/PingLoader.cpp
+++ b/third_party/WebKit/Source/core/loader/PingLoader.cpp
@@ -426,7 +426,7 @@ bool sendBeaconCommon(LocalFrame* frame,
return false;
unsigned long long entitySize = beacon.size();
- if (allowance > 0 && static_cast<unsigned long long>(allowance) < entitySize)
+ if (allowance < 0 || static_cast<unsigned long long>(allowance) < entitySize)
return false;
payloadLength = entitySize;
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/sendbeacon/beacon-allowance-limit.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698