Commit Graph

11039 Commits

Author SHA1 Message Date
Patrick McManus
175115e709 bug 1116867 - make nsIProgressEventSink and nsITransportEventSink safely scriptable r=mayhemer r=bz
These scriptable interfaces use uint_64 arguments with sentinel values
of UINT64_MAX. However, UINT64_MAX exceeds MAX_SAFE_INTEGER and cannot
be gatewayed to/from javascript - so they cannot be used
correctly. Change them to use signed 64 bit numbers and -1 as the
sentinnel. C++ implementations ought to be enough to audit as the
special value could never be used correctly in JS anyhow - also
audited OnProgressChange() uses for downstream use of this data.
---
 dom/base/nsXMLHttpRequest.cpp                      | 19 +++++++----
 dom/base/nsXMLHttpRequest.h                        | 10 +++---
 dom/plugins/base/nsPluginStreamListenerPeer.cpp    |  4 +--
 .../webbrowserpersist/nsWebBrowserPersist.cpp      | 14 ++++----
 image/src/imgLoader.cpp                            |  4 +--
 modules/libjar/nsJARChannel.cpp                    |  3 +-
 netwerk/base/public/nsIProgressEventSink.idl       |  8 ++---
 netwerk/base/public/nsITransport.idl               |  8 ++---
 netwerk/base/public/nsNetUtil.h                    | 24 ++++++++++++++
 netwerk/base/src/Dashboard.cpp                     |  2 +-
 netwerk/base/src/nsBaseChannel.cpp                 | 12 +++----
 netwerk/base/src/nsIncrementalDownload.cpp         |  4 +--
 netwerk/base/src/nsSocketTransport2.cpp            |  5 +--
 netwerk/base/src/nsStreamTransportService.cpp      | 38 +++++++++++++---------
 netwerk/base/src/nsTransportUtils.cpp              | 12 +++----
 netwerk/protocol/file/nsFileChannel.cpp            |  8 +++--
 netwerk/protocol/ftp/nsFtpConnectionThread.cpp     |  4 +--
 netwerk/protocol/http/Http2Push.cpp                |  2 +-
 netwerk/protocol/http/Http2Session.cpp             |  2 +-
 netwerk/protocol/http/HttpChannelChild.cpp         | 31 +++++++++---------
 netwerk/protocol/http/HttpChannelChild.h           |  6 ++--
 netwerk/protocol/http/HttpChannelParent.cpp        |  4 +--
 netwerk/protocol/http/HttpChannelParent.h          |  4 +--
 netwerk/protocol/http/NullHttpTransaction.cpp      |  2 +-
 netwerk/protocol/http/PHttpChannel.ipdl            |  2 +-
 netwerk/protocol/http/SpdyPush31.cpp               |  2 +-
 netwerk/protocol/http/SpdySession31.cpp            |  2 +-
 netwerk/protocol/http/TunnelUtils.cpp              |  2 +-
 netwerk/protocol/http/nsAHttpTransaction.h         |  4 +--
 netwerk/protocol/http/nsHttpChannel.cpp            | 30 +++++++++++------
 netwerk/protocol/http/nsHttpConnection.cpp         |  4 +--
 netwerk/protocol/http/nsHttpConnectionMgr.cpp      |  4 +--
 netwerk/protocol/http/nsHttpPipeline.cpp           |  4 +--
 netwerk/protocol/http/nsHttpPipeline.h             |  6 ++--
 netwerk/protocol/http/nsHttpResponseHead.cpp       |  2 +-
 netwerk/protocol/http/nsHttpResponseHead.h         |  2 +-
 netwerk/protocol/http/nsHttpTransaction.cpp        | 32 +++++++++---------
 netwerk/protocol/http/nsHttpTransaction.h          |  2 +-
 netwerk/protocol/wyciwyg/WyciwygChannelChild.cpp   |  2 +-
 netwerk/protocol/wyciwyg/nsWyciwygChannel.cpp      |  3 +-
 netwerk/test/TestIncrementalDownload.cpp           |  7 ++--
 uriloader/base/nsDocLoader.cpp                     | 14 ++++----
 42 files changed, 203 insertions(+), 151 deletions(-)
2015-01-08 14:48:52 -05:00
Patrick McManus
0587d8c35c bug 1102923 - move spdy/h2 tests off fixed port r=hurley r=ted 2015-01-15 11:12:05 -05:00
Nicholas Nethercote
8bd1f6f072 Bug 1123151 (part 2) - Add PLDHashTable::IsInitialized(). r=froydnj.
This encapsulates most of the uses of PLDHashTable::ops.

--HG--
extra : rebase_source : 7760ce8e46a37e87dcfe590e809a21df01fe510f
2015-01-19 16:11:34 -08:00
Nicholas Nethercote
bd573c9b9c Bug 1123151 (part 1) - Set PLDHashTable::ops consistently. r=froydnj.
Currently the setting of PLDHashTable::ops is very haphazard.

- PLDHashTable has no constructor, so it's not auto-nulled, so lots of places
  null it themselves.

- In the fallible PLDHashTable::Init() function, if the entry storage
  allocation fails we'll be left with a table that has |ops| set -- indicating
  it's been initialized -- but has null entry storage. I'm not certain this can
  cause problems but it feels unsafe, and some (but not all) callers of Init()
  null it on failure.

- PLDHashTable does not null |ops| in Finish(), so some (but not all) callers
  do this themselves.

This patch makes things simpler.

- It adds a constructor that zeroes |ops|.

- It modifies Init() so that it only sets |ops| once success is ensured.

- It zeroes |ops| in Finish().

- Finally, it removes all the now-unnecessary |ops| nulling done by the users
  of PLDHashTable.

--HG--
extra : rebase_source : bb34979c218d152562a2f9c7e5215256c111cc5b
2015-01-19 16:01:24 -08:00
Hiroyuki Ikezoe
35ea53baee Bug 1122540 - Set preferences which are necessary for passing xpcshell test on comm-central. r=hurley 2015-01-19 01:03:00 +02:00
Andrea Marchesini
9134a94a37 Bug 1123021 - Better life-time management for WebSocketChannelChild, r=smaug 2015-01-19 17:21:20 +00:00
Francois Marier
1346294463 Bug 1113004 - Add IsPrivateResponse to HttpChannel. r=mayhemer 2015-01-08 22:38:00 +01:00
Christoph Kerschbaumer
abb0caed63 Bug 1119006 - Remove files where code is still calling removed NS_OpenURI API (r=mcmanus) 2015-01-14 11:52:57 -08:00
Jeff Muizelaar
3f0fdb039e Bug 1114999 - Part 3: Use automatic memory management for mObjsToRelease; r=novotny 2015-01-15 18:19:26 -05:00
Valentin Gosu
f561749154 Bug 1121826 - backout cc192030c28f - brackets shouldn't be automatically escaped in the Query r=mcmanus 2015-01-17 16:13:21 +02:00
Nicholas Hurley
3cbacea502 Bug 1122532 - ensure making new URIs actually succeeds. r=mcmanus
--HG--
extra : rebase_source : b45ac17e073bb9751f49d85e39f184687f04e274
2015-01-16 07:32:26 -08:00
Kyle Huey
7c82e6dd0a Bug 1121673: Use move references in IPDL. r=bent 2015-01-16 11:58:52 -08:00
Patrick McManus
d0d97ad7ef bug 1072478 - h2 push hit not subject to max_concurrent 2/2 r=hurley
--HG--
extra : rebase_source : 4c49f74dc4b7ed8cead65dc3c78a2c8ae5ddf5e3
2015-01-13 15:26:37 -05:00
Patrick McManus
e2c3dd796f bug 1072478 - h2 push loses fin bit race condition 1/2 r=hurley
--HG--
extra : rebase_source : 25ba5077d89f4cbf4c1a8e93a3c4da1536260d83
2015-01-13 15:26:23 -05:00
Patrick McManus
dfe84c8ed8 bug 1121706 - don't offer h2 in alpn if w/out mandatory suite r=hurley
--HG--
extra : rebase_source : 6220a4ace1df2f6cc7f02c98f46b331b251a42d2
2015-01-15 22:11:14 -05:00
Benjamin Peterson
225eeb4f61 No bug - fix typo r=me DONTBUILD
--HG--
extra : amend_source : c2878d38f04cafa8327bacf8e537428252a89923
2015-01-16 10:32:55 -05:00
Ryan VanderMeulen
c2452803fa Bug 1111137 - Disable test_user_agent_overrides.html on Android due to frequent failures. 2015-01-16 09:59:57 -05:00
Dragana Damjanovic
bb144e96bc Bug 1108971 - Fix parameter in call GetAddrInfo. r=sworkman 2015-01-15 01:21:00 +01:00
Nicholas Nethercote
69fe655b04 Bug 1121304 (part 2, attempt 2) - Remove PLDHashTableOps::{alloc,free}Table. r=froydnj.
--HG--
extra : rebase_source : bc119bd0d3b6944e8c5a000950e0c4052cb70aef
2015-01-14 14:35:56 -08:00
Nicholas Nethercote
27ab169068 Bug 1121304 (part 1, attempt 2) - Minor type clean-ups for PLDHashTable. r=froydnj.
--HG--
extra : rebase_source : cccc747bf900804a566853d8eb7f16cf82a26978
2015-01-14 14:35:45 -08:00
Wes Kocher
cc2a95ecff Backed out changeset 3caf22d78fc5 (bug 1114999) for cache leaks on a CLOSED TREE
--HG--
extra : amend_source : 7d4c19ab2e39ade23e3759e169f5798a54116aed
2015-01-15 16:31:34 -08:00
Ehsan Akhgari
b2a268760f Bug 1116545 - Remove the code to handle shutdown-cleanse from the cache service; r=novotny
shutdown-cleanse has not been a thing for quite a while.
2015-01-15 18:21:42 -05:00
Jeff Muizelaar
9bab0efb09 Bug 1114999 - Part 3: Use automatic memory management for mObjsToRelease; r=novotny 2015-01-15 18:19:26 -05:00
Nicholas Hurley
87facfa179 Bug 1009122 - use cache2 as storage for predictor data. r=honzab
--HG--
extra : rebase_source : 290e1aa04a1dfa2e7d6cb9f1b5b705d1ed80e68c
2015-01-14 13:59:04 -08:00
Tooru Fujisawa
f22aabad26 Bug 1117580 - Throw an exception if PR_APPEND is passed without PR_TRUNCATE to nsAtomicFileOutputStream::Init. r=yoric 2015-01-16 00:01:46 +09:00
Daniel Stenberg
54e2e84910 Bug 1008091 - send network change events on FxOS and Linux, r=sworkman 2015-01-15 00:22:00 +01:00
Dragana Damjanovic
9ccb0f15a6 Bug 862856 - Send Http Activity notifications for speculative connections. r=mcmanus 2015-01-14 03:54:00 +01:00
Phil Ringnalda
e39f0adeca Backed out 2 changesets (bug 1121304) for consistent b2g hangs in webgl-color-test.html?frame=1&__&preserve&premult&_____
Backed out changeset 20651ac19549 (bug 1121304)
Backed out changeset 758afec77c95 (bug 1121304)
2015-01-14 22:02:23 -08:00
Nicholas Nethercote
e9735966fa Bug 1121304 (part 2) - Remove PLDHashTableOps::{alloc,free}Table. r=froydnj. 2015-01-14 14:35:56 -08:00
Nicholas Nethercote
41dc319a7c Bug 1121304 (part 1) - Minor type clean-ups for PLDHashTable. r=froydnj. 2015-01-14 14:35:45 -08:00
Nicholas Nethercote
47221bc7f9 Bug 1120476 (part 4) - Remove PLDHashTableOps::finalize. r=froydnj.
--HG--
extra : rebase_source : b14dda8cdd5cd896d1e32950e38b2a9f7da4d99e
2015-01-13 19:02:35 -08:00
Nicholas Nethercote
c7538c9776 Bug 1120476 (part 3) - Remove PLDHashTable::data. r=froydnj.
--HG--
extra : rebase_source : 24d10af3dbce3ada5252503bc80bb1a4e31bc1c9
2015-01-13 16:42:13 -08:00
Brian Smith
52dde4a9ae Bug 1119776, Part 5: Avoid defining snprintf when MSVC provides it (netwerk), r=rjesup
--HG--
extra : rebase_source : 8226d21a7685282a33fe5e813b5aae4892ab1435
2015-01-08 22:33:57 -08:00
Ehsan Akhgari
ea2e039efd Bug 1119256 - Mark virtual overridden functions as MOZ_OVERRIDE in netwerk; r=jduell 2015-01-14 17:57:08 -05:00
Nicholas Hurley
07dcfdb793 Bug 1121530 - improve poll failure logging. r=mcmanus
--HG--
extra : rebase_source : 5700682b71b2d6359cbfc3c6a80290fe2d28ed65
2015-01-14 08:39:09 -08:00
Monica Chew
269c62c45e Bug 1100024: Don't call Connect if the principal is on a local or remote blocklist (r=mcmanus)
* * *
Bug 1120547 - Mark the overrides of nsIHttpChannelInternal::ContinueBeginConnect as override and rev the uuid of the interface; r=mmc
2015-01-09 13:25:13 -08:00
Michal Novotny
43ffdfdac7 Bug 1117585 - Disk consumption observers could get released on the cache thread, r=jduell 2015-01-14 15:38:27 +01:00
Patrick McManus
33e101f503 bug 1121058 - h2 assert stream id before cleanup r=hurley 2015-01-13 13:10:38 -05:00
Andrea Marchesini
f9e16e16fb Bug 1111971 - patch 2 - private DTOR for ListenerAndContextContainer, CLOSED TREE 2015-01-13 19:26:59 +00:00
Andrea Marchesini
4fbc443f4e Bug 1111971 - A better life-time management of aListener and aContext in WebSocketChannel. r=smaug
CLOSED TREE
2015-01-13 14:03:56 -05:00
James Cheng
5eb957de27 Bug 1104422 - Use PBrowserOrId to replace tabChild in SendAsyncOpen. r=honzab 2015-01-11 18:35:00 +01:00
Daniel Stenberg
f4c5e582cc Bug 1119717 - add nsNotifyAddr logging. r=mcmanus 2015-01-09 02:29:00 +01:00
Valentin Gosu
d855dd7639 Bug 1093611 - nsStandardURL::SetRef only does percent-encoding if dom.url.encode_decode_hash is true r=honzab 2015-01-13 02:11:02 +02:00
Patrick McManus
a12670699c bug 1119280 - fix large spdy/h2 transfer truncation r=hurley 2015-01-09 10:18:28 -05:00
Monica Chew
d2b4dc884c Bug 1100024: CLOSED TREE Backout https://hg.mozilla.org/integration/mozilla-inbound/rev/671ad56e6e12 for causing crashes on ClassifyLocal lookups (r=backout) 2015-01-12 10:05:58 -08:00
Christoph Kerschbaumer
54b8e4e5e4 Bug 1110469 - Remove NS_OpenURI (r=sworkman) 2015-01-11 20:26:40 -08:00
Christoph Kerschbaumer
1969a22887 Bug 1113323 - Make sure Protocolhandler sets same instance of loadinfo on the newly created channel (r=sicking) 2015-01-11 20:21:37 -08:00
Chris Peterson
89d65e0f17 Bug 1120159 - Replace nonstandard expression closure with an arrow function in file:// directory listing. r=mcmanus 2015-01-10 23:20:22 -08:00
Randell Jesup
9c505baf27 Bug 1030372: use explicit runnable and Release for ReadBlob to avoid wrong-thread release assert r=bsmedberg relanding on a CLOSED TREE
--HG--
extra : amend_source : 4351ac6c3a17885cd5a24d19c080ff8aa610de3f
2015-01-11 00:28:34 -05:00
Tom Schuster
967d0d250a Backout changeset b4ebefd0f7e3:a8044fd506db Bug 1117607, Bug 1118087, Bug 1118092, Bug 1118105, Bug 1030372, Bug 1079627 on CLOSED TREE 2015-01-11 20:43:32 +01:00