Граф коммитов

4572 Коммитов

Автор SHA1 Сообщение Дата
Gabriele Svelto 5dc21d568c Bug 1600545 - Remove useless inclusions of header files generated from IDL files in modules/, netwerk/, parser/, security/, startupcache/, storage/, toolkit/, tools/, uriloader/, widget/, xpcom/ and xpfe/ r=Ehsan
The inclusions were removed with the following very crude script and the
resulting breakage was fixed up by hand. The manual fixups did either
revert the changes done by the script, replace a generic header with a more
specific one or replace a header with a forward declaration.

find . -name "*.idl" | grep -v web-platform | grep -v third_party | while read path; do
    interfaces=$(grep "^\(class\|interface\).*:.*" "$path" | cut -d' ' -f2)
    if [ -n "$interfaces" ]; then
        if [[ "$interfaces" == *$'\n'* ]]; then
          regexp="\("
          for i in $interfaces; do regexp="$regexp$i\|"; done
          regexp="${regexp%%\\\|}\)"
        else
          regexp="$interfaces"
        fi
        interface=$(basename "$path")
        rg -l "#include.*${interface%%.idl}.h" . | while read path2; do
            hits=$(grep -v "#include.*${interface%%.idl}.h" "$path2" | grep -c "$regexp" )
            if [ $hits -eq 0 ]; then
                echo "Removing ${interface} from ${path2}"
                grep -v "#include.*${interface%%.idl}.h" "$path2" > "$path2".tmp
                mv -f "$path2".tmp "$path2"
            fi
        done
    fi
done

Differential Revision: https://phabricator.services.mozilla.com/D55444

--HG--
extra : moz-landing-system : lando
2019-12-06 09:17:57 +00:00
Boris Zbarsky 75124bdd98 Bug 1517588. Use nsIPrincipal::IsSystemPrincipal instead of nsContentUtils::IsSystemPrincipal r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D53067

--HG--
extra : moz-landing-system : lando
2019-12-05 04:44:32 +00:00
Kai Engert 7cf205fd2c Bug 1600429 - Add ability to strip conditional CSS rules, only. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D55350

--HG--
extra : moz-landing-system : lando
2019-12-03 07:04:50 +00:00
Honza Bambas ce072f8e6a Bug 1594449 - <link rel="preload"> implemented as a speculative load initiated during the prescan phase in the HTML5 parser, disabled by default, only supports "script" and "styles" types, r=ckerschb
Differential Revision: https://phabricator.services.mozilla.com/D52019

--HG--
extra : moz-landing-system : lando
2019-11-27 21:45:12 +00:00
Henri Sivonen e1d4e7fa2c Bug 1594672 - Add the "as" attribute to the HTML parser. r=alchen
Also makes mozilla/ImportScanner.h part of the translation process.

Differential Revision: https://phabricator.services.mozilla.com/D52135

--HG--
extra : moz-landing-system : lando
2019-11-22 16:55:58 +00:00
Will Hawkins c259811ab9 Bug 1513292: Make sure that a script's speculative load operation is started before its creation operation is executed. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D50170

--HG--
extra : moz-landing-system : lando
2019-11-22 09:19:20 +00:00
Sebastian Hengst 0341151d63 Bug 1594981 - update Core::DOM* and Core::Storage* bugzilla product and component meta data in moz.build files after reorganization in bug 1594717. r=annevk
Differential Revision: https://phabricator.services.mozilla.com/D52345

--HG--
extra : moz-landing-system : lando
2019-11-08 12:17:57 +00:00
Brian Grinstead d981495450 Bug 1593119 - Remove dom/xbl and the MOZ_XBL build option r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D51338

--HG--
extra : moz-landing-system : lando
2019-11-07 00:35:32 +00:00
Brian Grinstead f19f38776b Bug 1593119 - unifdef MOZ_XBL r=bzbarsky
This was generated with:

```
rg -l -g '*.{cpp,h}' MOZ_XBL . | while read FILE ; do
   echo $FILE
   unifdef -m -UMOZ_XBL $FILE
done
```

After this, I manually removed the directive in nsContentUtils.cpp due to:

  unifdef: ./dom/base/nsContentUtils.cpp: 4630: Unterminated string literal
  unifdef: Output may be truncated

Differential Revision: https://phabricator.services.mozilla.com/D51337

--HG--
extra : moz-landing-system : lando
2019-11-07 00:35:13 +00:00
Mirko Brodesser b2de103bf9 Bug 1593222: part 12) Rename "nsNodeUtils.*" to "MutationObservers.*". r=smaug
Depends on D51827

Differential Revision: https://phabricator.services.mozilla.com/D51828

--HG--
rename : dom/base/nsNodeUtils.cpp => dom/base/MutationObservers.cpp
rename : dom/base/nsNodeUtils.h => dom/base/MutationObservers.h
extra : moz-landing-system : lando
2019-11-06 09:08:06 +00:00
Mirko Brodesser ba0285f534 Bug 1593222: part 9) Move non-animation notification methods from `nsNodeUtils` to `MutationObservers`. r=smaug
The remaining notification methods are moved in a separate commit. The
files are renamed to `MutationObservers.*` in a follow-up commit.

Depends on D51824

Differential Revision: https://phabricator.services.mozilla.com/D51825

--HG--
extra : moz-landing-system : lando
2019-11-05 21:32:53 +00:00
Mirko Brodesser b845b4e662 Bug 1593222: part 1) Move `nsNodeUtils::IsTemplateElement` to `nsINode`. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D51606

--HG--
extra : moz-landing-system : lando
2019-11-05 14:05:36 +00:00
Alex Catarineu 08a431f34e Bug 1581537 - Avoid several browser language leaks r=smaug
Spoof dom/dom.properties, layout/xmlparser.properties,
layout/MediaDocument.properties to en-US if needed.

Differential Revision: https://phabricator.services.mozilla.com/D46034

--HG--
extra : moz-landing-system : lando
2019-11-04 16:56:27 +00:00
Mihai Alexandru Michis d19c1272ca Backed out changeset 1d87c269da8a (bug 1581537) for causing bc failures in browser_misused_characters_in_strings.js CLOSED TREE
--HG--
extra : rebase_source : b9f2da6650a4213a4a9284d6dbe7ecfd97761501
extra : amend_source : b7ca833a091419a2de5904eccb2d3ce9d0fcd337
2019-11-04 16:06:37 +02:00
Alex Catarineu ea206b140d Bug 1581537 - Avoid several browser language leaks r=smaug
Spoof dom/dom.properties, layout/xmlparser.properties,
layout/MediaDocument.properties to en-US if needed.

Differential Revision: https://phabricator.services.mozilla.com/D46034

--HG--
extra : moz-landing-system : lando
2019-11-04 11:27:59 +00:00
Geoff Brown de6c41dd8a Bug 1585119 - Re-enable yet more mochitests on android; r=geckoview-reviewers,snorp
Most of these tests have been disabled for a long time; they run well
in the current test environment.
This completes my review of skipped Android tests.

Differential Revision: https://phabricator.services.mozilla.com/D49954

--HG--
extra : moz-landing-system : lando
2019-10-22 20:10:27 +00:00
Brendan Dahl c68cd30ef2 Bug 1510785 - Only build XBL related code when MOZ_XBL is defined. r=bzbarsky
When XBL is disabled, no code in dom/xbl will be built. Also, adds ifdefs
to remove any of the XBL related code elsewhere. There's definitely more
that can be done here, but I think it's better to wait to do the rest of
the cleanup when we actually remove the code.

Depends on D45612

Differential Revision: https://phabricator.services.mozilla.com/D45613

--HG--
extra : moz-landing-system : lando
2019-10-08 23:52:14 +00:00
Peter Van der Beken baaea5c0bc Bug 1584907 - Deny internal entities closing the doctype. r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D47704

--HG--
extra : moz-landing-system : lando
2019-10-04 09:38:58 +00:00
Emilio Cobos Álvarez 453ca45319 Bug 1585674 - Start loads more incrementally in the @import scanner. r=hsivonen
Consider the case of a very big <style> element, with a few imports on top,
which we cut half-way over the network.

The @import scanner would be likely to have found anything there is to be found,
but we won't process it until we pop the <style> element. It's relatively low
effort to support this use-case by making Scan() return the already-found urls.

Differential Revision: https://phabricator.services.mozilla.com/D47914

--HG--
extra : moz-landing-system : lando
2019-10-03 07:34:35 +00:00
Henri Sivonen b50f974094 Bug 1584216 - Adjust tokenization of U+0000. r=alchen
Differential Revision: https://phabricator.services.mozilla.com/D47594

--HG--
extra : moz-landing-system : lando
2019-10-01 12:26:55 +00:00
Emilio Cobos Álvarez 1f94271c1d Bug 1546783 - Speculatively load @import rules inside <style>. r=bzbarsky,hsivonen
We don't bother handling the nested element case amazingly. We'd instead stop
at the inner <style> element and drop the URLs from the outer.

But I think that's ok. Any good way to test this? I've verified it does the
right thing looking at the CSS loader logs, but... :)

Differential Revision: https://phabricator.services.mozilla.com/D47471

--HG--
extra : moz-landing-system : lando
2019-09-30 13:39:33 +00:00
Emilio Cobos Álvarez 6195ff232c Bug 1546783 - Stop speculatively trying to load <svg:style xlink:href>. r=bzbarsky
That doesn't make much sense to me.

Differential Revision: https://phabricator.services.mozilla.com/D47470

--HG--
extra : moz-landing-system : lando
2019-09-30 13:29:21 +00:00
Coroiu Cristina b3555c999a Backed out 3 changesets (bug 1546783) on request by emilio on a CLOSED TREE
Backed out changeset ad3822105edc (bug 1546783)
Backed out changeset a8ac28c2bfc7 (bug 1546783)
Backed out changeset b2678d2e55fb (bug 1546783)
2019-09-30 16:23:16 +03:00
Emilio Cobos Álvarez f65a6de55c Bug 1546783 - Speculatively load @import rules inside <style>. r=bzbarsky,hsivonen
We don't bother handling the nested element case amazingly. We'd instead stop
at the inner <style> element and drop the URLs from the outer.

But I think that's ok. Any good way to test this? I've verified it does the
right thing looking at the CSS loader logs, but... :)

Differential Revision: https://phabricator.services.mozilla.com/D47471

--HG--
extra : moz-landing-system : lando
2019-09-30 13:00:22 +00:00
Emilio Cobos Álvarez bc0624be6a Bug 1546783 - Stop speculatively trying to load <svg:style xlink:href>. r=bzbarsky
That doesn't make much sense to me.

Differential Revision: https://phabricator.services.mozilla.com/D47470

--HG--
extra : moz-landing-system : lando
2019-09-30 10:37:24 +00:00
Alex Catarineu 8d86dd4c94 Bug 1573276 - Always allow localization in error pages r=johannh,peterv
Differential Revision: https://phabricator.services.mozilla.com/D43216

--HG--
extra : moz-landing-system : lando
2019-09-25 10:39:45 +00:00
Henri Sivonen c193518677 Bug 1490601 part 2 - Move C++ entry points to encoding_c_mem to mfbt/. r=jwalden
Differential Revision: https://phabricator.services.mozilla.com/D43957

--HG--
extra : moz-landing-system : lando
2019-09-18 08:26:34 +00:00
Brendan Dahl 5915a3e4bf Bug 1575620 - Fix refreshing session restore when using prototype cache. r=smaug
The session restore page keeps its restore list within a text input field
so that the values are persisted even if the page is refreshed. When form
elements were loaded with the prototype cache we didn't call
DoneCreatingElement after creating the element, which means the form values
weren't restored.

The list of elements that require DoneCreatingElement and DoneAddingChildren
to be called was in three (now four) different places, so I moved them to
a central spot in nsIContent to share in all locations. This also highlighted
that the check for <output> nodes is missing from the XML content sink.

Differential Revision: https://phabricator.services.mozilla.com/D44866

--HG--
extra : moz-landing-system : lando
2019-09-06 20:27:09 +00:00
shindli b99fd194b2 Backed out changeset 5e9663384022 (bug 1575620) for causing bustages in builds/worker/workspace/build/src/obj-firefox/dist/include/nsIContent.h CLOSED TREE 2019-09-06 22:47:18 +03:00
Brendan Dahl c377fd351d Bug 1575620 - Fix refreshing session restore when using prototype cache. r=smaug
The session restore page keeps its restore list within a text input field
so that the values are persisted even if the page is refreshed. When form
elements were loaded with the prototype cache we didn't call
DoneCreatingElement after creating the element, which means the form values
weren't restored.

The list of elements that require DoneCreatingElement and DoneAddingChildren
to be called was in three (now four) different places, so I moved them to
a central spot in nsIContent to share in all locations. This also highlighted
that the check for <output> nodes is missing from the XML content sink.

Differential Revision: https://phabricator.services.mozilla.com/D44866

--HG--
extra : moz-landing-system : lando
2019-09-05 22:26:25 +00:00
Sylvestre Ledru d264b841c9 Bug 1576502 - Fix some wording issues r=mhoye
Differential Revision: https://phabricator.services.mozilla.com/D43363

--HG--
extra : moz-landing-system : lando
2019-08-27 15:38:58 +00:00
Alphan Chen fc59938bee Bug 1482885 - Refactor nsHtml5TreeOperation's enum plus fields into mozilla::Variant r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D42809

--HG--
extra : moz-landing-system : lando
2019-08-27 09:39:41 +00:00
Thomas Nguyen cf20303f06 Bug 1528697 - Remove ReferrerPolicy.h and add utils to ReferrerInfo r=ckerschb
Differential Revision: https://phabricator.services.mozilla.com/D41956

--HG--
extra : moz-landing-system : lando
2019-08-21 12:09:06 +00:00
Thomas Nguyen 32ab8293ff Bug 1528697 - Expose ReferrerPolicy.webidl and use referrerpolicy enum r=smaug
ReferrerPolicy gets tossed back and forth as a uint32_t and
ReferrerPolicy enum in header file. Expose ReferrerPolicyValues from
webidl file and use consistently in native code.

Differential Revision: https://phabricator.services.mozilla.com/D41954

--HG--
extra : moz-landing-system : lando
2019-08-21 13:24:45 +00:00
Sylvestre Ledru 645f2d5773 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D41559

--HG--
extra : moz-landing-system : lando
2019-08-13 07:15:25 +00:00
Tom Schuster 0e913c22c4 Bug 1558915 - Use infallible nsIURI::SchemeIs in various places r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D40677

--HG--
extra : moz-landing-system : lando
2019-08-07 19:49:40 +00:00
Cosmin Sabou c3430326e6 Backed out changeset ca88862d6b63 (bug 1558915) for causing build bustages on StartupCacheUtils. CLOSED TREE 2019-08-07 13:20:32 +03:00
Tom Schuster 8bc1f5ada8 Bug 1558915 - Use infallible nsIURI::SchemeIs in various places r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D40677

--HG--
extra : moz-landing-system : lando
2019-08-07 09:36:56 +00:00
Razvan Maries eedbf1137f Backed out changeset b197ca57677a (bug 1558915) for build bustages. CLOSED TREE 2019-08-07 01:04:43 +03:00
Tom Schuster 03c7998ef2 Bug 1558915 - Use infallible nsIURI::SchemeIs in various places r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D40677

--HG--
extra : moz-landing-system : lando
2019-08-06 20:19:41 +00:00
Henri Sivonen 3623f75636 Bug 1562033. r=alchen
Differential Revision: https://phabricator.services.mozilla.com/D36361

--HG--
extra : moz-landing-system : lando
2019-07-08 07:33:59 +00:00
Brian Hackett eb95b88a4d Bug 1538056 Part 1 - Notify devtools about HTML file contents, r=hsivonen.
Differential Revision: https://phabricator.services.mozilla.com/D33178

--HG--
extra : moz-landing-system : lando
2019-08-04 21:33:07 +00:00
kriswright a6e61ca131 Bug 1570082 - Convert content.sink.*_parse_time to static pref. r=njn
Converts varcache prefs content.sink.interactive_parse_time and content.sink.perf_parse_time to static prefs.

Differential Revision: https://phabricator.services.mozilla.com/D40138

--HG--
extra : moz-landing-system : lando
2019-08-01 17:15:49 +00:00
Sebastian Streich 6917b697b8 Bug 1428473 Support X-Content-Type-Options: nosniff when navigating r=ckerschb,dragana,alchen
***
Apply Requested Revision

Differential Revision: https://phabricator.services.mozilla.com/D33959

--HG--
extra : moz-landing-system : lando
2019-07-31 16:59:53 +00:00
Kannan Vijayan 3fb6190ec6 Bug 1559414 - Rename unaudited pre-fission methods with SameProcess for future audit burndown. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D39378

--HG--
extra : moz-landing-system : lando
2019-07-26 16:48:31 +00:00
Nicholas Nethercote 18fae65f38 Bug 1563139 - Remove StaticPrefs.h. r=glandium
This requires replacing inclusions of it with inclusions of more specific prefs
files.

The exception is that StaticPrefsAll.h, which is equivalent to StaticPrefs.h,
and is used in `Codegen.py` because doing something smarter is tricky and
suitable for a follow-up. As a result, any change to StaticPrefList.yaml will
still trigger recompilation of all the generated DOM bindings files, but that's
still a big improvement over trigger recompilation of every file that uses
static prefs.

Most of the changes in this commit are very boring. The only changes that are
not boring are modules/libpref/*, Codegen.py, and ServoBindings.toml.

Differential Revision: https://phabricator.services.mozilla.com/D39138

--HG--
extra : moz-landing-system : lando
2019-07-26 01:10:23 +00:00
Emilio Cobos Álvarez 2189015730 Bug 1565129 - Re-introduce plain_text.wrap_long_lines. r=bzbarsky
Looks like some users use it, and it's not too much effort to support. This is
somewhat simpler, and IMO better than what existed before bug 1514655 because:

 * It doesn't regress bidi rendering when the pref is disabled (before, the pref
   would prevent plaintext.css from applying altogether).

 * It's consistent with the way view-source docs work.

 * It doesn't use non-standard stylesheet APIs to toggle the stylesheet
   (bug 1260720).

Differential Revision: https://phabricator.services.mozilla.com/D37742

--HG--
extra : moz-landing-system : lando
2019-07-11 18:49:50 +00:00
Bogdan Tara fa0329b09b Backed out changeset 6f468ad73df2 (bug 1565129) for causing leaks CLOSED TREE 2019-07-11 21:00:59 +03:00
Emilio Cobos Álvarez f75dd725f5 Bug 1565129 - Re-introduce plain_text.wrap_long_lines. r=bzbarsky
Looks like some users use it, and it's not too much effort to support. This is
somewhat simpler, and IMO better than what existed before bug 1514655 because:

 * It doesn't regress bidi rendering when the pref is disabled (before, the pref
   would prevent plaintext.css from applying altogether).

 * It's consistent with the way view-source docs work.

 * It doesn't use non-standard stylesheet APIs to toggle the stylesheet
   (bug 1260720).

Differential Revision: https://phabricator.services.mozilla.com/D37742

--HG--
extra : moz-landing-system : lando
2019-07-11 16:32:08 +00:00
Alex Catarineu a8b667f825 Bug 467035 - Avoid leaking browser language via DTD r=Gijs,bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D34187

--HG--
extra : moz-landing-system : lando
2019-07-08 10:47:05 +00:00
Victor Porof 572c392d30 Bug 1561435 - Format parser/, a=automatic-formatting
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D35923

--HG--
extra : source : 03ab20f6337a695a31afb301410182972e4195a9
2019-07-05 10:56:19 +02:00
Boris Zbarsky 8c4e35413a Bug 1559008. Load catalog DTDs even if we don't have a useful DTD URI, since we ignore that URI anyway when we find a catalog DTD. r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D34815

--HG--
extra : moz-landing-system : lando
2019-06-24 12:45:22 +00:00
Henri Sivonen f17219eabd Bug 1555523. r=alchen
Differential Revision: https://phabricator.services.mozilla.com/D33639

--HG--
extra : moz-landing-system : lando
2019-06-15 12:45:57 +00:00
Jonathan Kingston a5ba216f93 Bug 1315460 - Removal of keygen element r=keeler,baku,jld,hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D22810

--HG--
extra : moz-landing-system : lando
2019-06-13 08:58:07 +00:00
Boris Zbarsky d5a8a4a595 Bug 1557793 part 3. Change the signatures of various nsContentUtils localization methods to play nicer with the new stringbundle API. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D34201

--HG--
extra : moz-landing-system : lando
2019-06-08 21:26:12 +00:00
Zibi Braniecki 963c84b982 Bug 1539714 - Trigger initial localization even if layout started. r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D34400

--HG--
extra : moz-landing-system : lando
2019-06-10 20:06:08 +00:00
Thomas Nguyen 01ff0bf93f Bug 1534681 Use ReferrerInfo class in document r=ckerschb,baku,Gijs
Also, in many place, we use document uri as referrer. It is not right
for the case srdoc iframe. We should use the last non-srdoc parent
document's uri

Differential Revision: https://phabricator.services.mozilla.com/D30191

--HG--
rename : testing/web-platform/tests/referrer-policy/generic/iframe-inheritance.html => testing/web-platform/tests/referrer-policy/generic/inheritance/iframe-inheritance-data.html
rename : testing/web-platform/tests/referrer-policy/generic/iframe-inheritance.html => testing/web-platform/tests/referrer-policy/generic/inheritance/iframe-inheritance-srcdoc.html
extra : moz-landing-system : lando
2019-06-06 07:23:37 +00:00
Ehsan Akhgari adf073ce68 Bug 836176 - Part 3: Remove nsIHTMLDocument; r=farre
Differential Revision: https://phabricator.services.mozilla.com/D32925

--HG--
extra : moz-landing-system : lando
2019-06-04 17:27:43 +00:00
Masatoshi Kimura 2d731ea4c9 Bug 1556746 - Remove kCharsetFromHintPrevDoc that have been accidentally restored by resolving merge conflict. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D33642

--HG--
extra : moz-landing-system : lando
2019-06-04 14:47:34 +00:00
Cosmin Sabou d68454d1da Bug 1543077 - Fix merge conflict bustage, add missing comma. r=bustage-fix CLOSED TREE
--HG--
extra : amend_source : 81882c10b7f3bee85f2acb3a38489b566f4684c1
2019-06-03 19:49:09 +03:00
Cosmin Sabou bcd5ff3d98 Merge mozilla-central to autoland.
--HG--
extra : rebase_source : ec8335cc4fb4f7c2594b2b95cd6d5078af2be625
2019-06-03 19:24:20 +03:00
Henri Sivonen 6a2647d5f9 Bug 1543077 part 5 - Enable autodetect of ISO-2022-JP for local files when Fallback Encoding is set to Japanese. r=emk.
Differential Revision: https://phabricator.services.mozilla.com/D28635
2019-06-03 15:30:41 +03:00
Henri Sivonen ae34dc651a Bug 1543077 part 4 - Have only one item for Japanese in the Text Encoding menu. r=Gijs,emk.
Differential Revision: https://phabricator.services.mozilla.com/D28634
2019-06-03 15:30:41 +03:00
Henri Sivonen 0a2e1dfc79 Bug 1543077 part 2 - Use mozilla::JapaneseDetector in the HTML parser. r=emk.
Differential Revision: https://phabricator.services.mozilla.com/D27793
2019-06-03 15:30:41 +03:00
Masatoshi Kimura b411f04b5f Bug 1554589 - Turn nsCharsetSource constants into an enum. r=hsivonen
Since unscoped enums implicitly convert to underlying types, we don't have to change everything at once. It is worth enough to introduce auto-numbering, IMO.

Differential Revision: https://phabricator.services.mozilla.com/D32841

--HG--
extra : moz-landing-system : lando
2019-06-03 09:13:50 +00:00
Ehsan Akhgari ad6a833e39 Bug 1549560 - Move HTMLDocument.open/close/write/writeln to Document; r=farre
Differential Revision: https://phabricator.services.mozilla.com/D32388

--HG--
extra : moz-landing-system : lando
2019-05-27 23:03:03 +00:00
Bogdan Tara 2bcd3a4566 Backed out changeset c352b73db92b (bug 1549560) for dom/base/Document.cpp related build bustages CLOSED TREE 2019-05-27 23:57:00 +03:00
Ehsan Akhgari 6b308d9e98 Bug 1549560 - Move HTMLDocument.open/close/write/writeln to Document; r=farre
Differential Revision: https://phabricator.services.mozilla.com/D32388

--HG--
extra : moz-landing-system : lando
2019-05-27 18:42:23 +00:00
Mihai Alexandru Michis 1dd6cb6ee5 Backed out 6 changesets (bug 1543077) for causing bc failures at docshell/test/browser/browser_bug1543077.js
Backed out changeset f593045cc48f (bug 1543077)
Backed out changeset 25449ba8aceb (bug 1543077)
Backed out changeset ccc438262e29 (bug 1543077)
Backed out changeset 4573c25b1ce0 (bug 1543077)
Backed out changeset 1cbaafb9373a (bug 1543077)
Backed out changeset 1a0e7ced8e47 (bug 1543077)

--HG--
extra : rebase_source : f04bf405303fe03776f0e70b03db076c0a41ae45
2019-05-27 12:00:21 +03:00
Henri Sivonen 5e954d8018 Bug 1543077 part 5 - Enable autodetect of ISO-2022-JP for local files when Fallback Encoding is set to Japanese. r=emk
Differential Revision: https://phabricator.services.mozilla.com/D28635

--HG--
extra : moz-landing-system : lando
2019-05-27 07:55:29 +00:00
Henri Sivonen 533527938d Bug 1543077 part 4 - Have only one item for Japanese in the Text Encoding menu. r=emk,Gijs
Differential Revision: https://phabricator.services.mozilla.com/D28634

--HG--
extra : moz-landing-system : lando
2019-05-27 07:55:27 +00:00
Henri Sivonen 1953910dd3 Bug 1543077 part 2 - Use mozilla::JapaneseDetector in the HTML parser. r=emk
Depends on D27792

Differential Revision: https://phabricator.services.mozilla.com/D27793

--HG--
extra : moz-landing-system : lando
2019-05-27 07:56:17 +00:00
Sylvestre Ledru d57d4905f1 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D30883

--HG--
extra : moz-landing-system : lando
2019-05-25 17:46:15 +00:00
arthur.iakab af8e458c5f Backed out changeset a296439a25ff (bug 1519636) for frequent Windows cppunit failures CLOSED TREE 2019-05-24 14:26:01 +03:00
Sylvestre Ledru c82ea97226 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D30883

--HG--
extra : moz-landing-system : lando
2019-05-24 09:59:17 +00:00
Sylvestre Ledru 993c03acb1 Bug 1552795 - Remove all trailing whitespaces in idl files r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D31769

--HG--
extra : moz-landing-system : lando
2019-05-22 22:37:14 +00:00
Christoph Kerschbaumer b633427366 Bug 965637: Move CSP from Principal into Client, part 1: backend changes. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D27654

--HG--
extra : moz-landing-system : lando
2019-05-21 23:14:27 +00:00
Peter Van der Beken 3991c12564 Bug 1539759 - Improve DTD entity handling. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D30248

--HG--
extra : moz-landing-system : lando
2019-05-21 18:24:02 +00:00
Boris Zbarsky f6c8cd1d10 Bug 1550524 part 3. Remove the now-unused aContentType argument to nsHtml5Parser::Parse. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D30752

--HG--
extra : moz-landing-system : lando
2019-05-14 19:46:26 +00:00
Boris Zbarsky dd41010b5d Bug 1550524 part 2. Add an explicit StartExecutor method on nsHtml5Parser, for use from document.open(). r=hsivonen
The code has mostly moved, but there are a few simplifications:

1) If !GetStreamParser(), then GetChannel() always returns null and hence we
never set isSrcdoc to true.  Which is good, because we don't want to apply the
special srcdoc-parsing rules to document.open() stuff.  So we just pass false
to setIsSrcdocDocument(): It's the same behavior as before, but a lot clearer.
I've confirmed that code coverage says the "isSrcdoc =
NS_IsSrcdocChannel(channel)" line is unreached in our tests.

2) In the document.write-after-document.open case, aContentType is now always
"text/html" (because that's what document.open sets mContentTypeForWriteCalls
to.  So the block checking for it not being "text/html" was dead code (also
confirmed via code coverage results) and I'm just removing it.

Differential Revision: https://phabricator.services.mozilla.com/D30751

--HG--
extra : moz-landing-system : lando
2019-05-14 19:46:26 +00:00
Boris Zbarsky 0c6443c5e8 Bug 1550524 part 1. Make NewHtml5Parser() return an nsHtml5Parser. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D30750

--HG--
extra : moz-landing-system : lando
2019-05-14 19:46:25 +00:00
Mihai Alexandru Michis 8187c0826d Backed out changeset 16c03995ac55 (bug 1539759) for causing Buffer Overflow in nsExpatDriver.cpp
--HG--
extra : rebase_source : 0b9e64681becc725d8550f4a6820166ce8fba2bf
2019-05-13 18:16:39 +03:00
Peter Van der Beken 068b07cee6 Bug 1539759 - Improve DTD entity handling. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D30248

--HG--
extra : moz-landing-system : lando
2019-05-13 07:32:42 +00:00
Boris Zbarsky 89d6eb2831 Bug 325352 part 1. Align our "defined insertion point" concept more closely with the spec's "script nesting level" concept. r=hsivonen
This also exposes an accessor for whether the parser has a nonzero script nesting level.

Differential Revision: https://phabricator.services.mozilla.com/D30313

--HG--
extra : moz-landing-system : lando
2019-05-08 06:10:47 +00:00
Cosmin Sabou 58c0da101a Backed out changeset 03166449953f (bug 1539759) on request from past for causing bug 1548990. CLOSED TREE 2019-05-04 11:02:30 +03:00
Gijs Kruitbosch c1c14ab7ad Bug 1539759 - improve DTD entity handling, r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D27904

--HG--
extra : moz-landing-system : lando
2019-05-03 09:13:58 +00:00
Narcis Beleuzu c8e45a1834 Backed out changeset 4c6e2e3f23f9 (bug 1539759) for failures on nsExpatDriver::WillBuildModel . CLOSED TREE 2019-05-02 13:42:29 +03:00
Gijs Kruitbosch 54d985d143 Bug 1539759 - improve DTD entity handling, r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D27904

--HG--
extra : moz-landing-system : lando
2019-05-02 09:22:10 +00:00
Oana Pop Rus 594cead134 Backed out changeset 5f451bcec205 (bug 1539759) for build bustages in nsExpatDriver.cpp on a CLOSED TREE 2019-05-02 11:52:32 +03:00
Gijs Kruitbosch 170118c247 Bug 1539759 - improve DTD entity handling, r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D27904

--HG--
extra : moz-landing-system : lando
2019-05-02 08:19:08 +00:00
Sylvestre Ledru e226046cb8 Bug 1547143 - Format the tree: Be prescriptive with the pointer style (left) r=Ehsan
# ignore-this-changeset

Depends on D28954

Differential Revision: https://phabricator.services.mozilla.com/D28956

--HG--
extra : moz-landing-system : lando
2019-05-01 08:47:10 +00:00
Emilio Cobos Álvarez 9027ab34a7 Bug 1514655 - Always wrap plain text documents. r=bzbarsky
This matches other UAs.

Differential Revision: https://phabricator.services.mozilla.com/D14848

--HG--
extra : moz-landing-system : lando
2019-04-30 19:41:40 +00:00
Brian Grinstead ede8c44ef2 Bug 1544322 - Part 2.1 - Remove the [type] attribute for one-liner <script> tags loading files in /tests/SimpleTest/ in everything except for dom/ r=bzbarsky
This excludes dom/, otherwise the file size is too large for phabricator to handle.

This is an autogenerated commit to handle scripts loading mochitest harness files, in
the simple case where the script src is on the same line as the tag.

This was generated with https://bug1544322.bmoattachments.org/attachment.cgi?id=9058170
using the `--part 2` argument.

Differential Revision: https://phabricator.services.mozilla.com/D27456

--HG--
extra : moz-landing-system : lando
2019-04-16 03:50:44 +00:00
Henri Sivonen f09eac321f Bug 1540757 - Mark SVG scripts as malformed when popped by HTML breakout from foreign content. r=alchen
Differential Revision: https://phabricator.services.mozilla.com/D26276
2019-04-15 13:40:14 +03:00
Henri Sivonen 38ab798925 Bug 1540675 - Handle line breaks correctly in comment end bang state. r=alchen.
Differential Revision: https://phabricator.services.mozilla.com/D25594
2019-04-15 13:40:14 +03:00
Andrea Marchesini a438b12ebd Bug 1536411 - StoragePrincipal - part 1 - Implementation, r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D24025

--HG--
extra : moz-landing-system : lando
2019-04-12 05:31:32 +00:00
Cosmin Sabou af07021e88 Backed out 10 changesets (bug 1536411) for causing leaks in CondVar, MessagePortService, MessagePortServiceData.
Backed out changeset eda5854cd7e8 (bug 1536411)
Backed out changeset f94dfbf2476c (bug 1536411)
Backed out changeset c68dc3152faa (bug 1536411)
Backed out changeset f67d157e8baf (bug 1536411)
Backed out changeset 1107a9767f38 (bug 1536411)
Backed out changeset ccbe1af00fb9 (bug 1536411)
Backed out changeset 552c4b588524 (bug 1536411)
Backed out changeset 2eb20578159b (bug 1536411)
Backed out changeset 45708d22bb6d (bug 1536411)
Backed out changeset 87601ef1d4d4 (bug 1536411)
2019-04-11 22:48:49 +03:00
Andrea Marchesini 5cfeeda19e Bug 1536411 - StoragePrincipal - part 1 - Implementation, r=Ehsan
Differential Revision: https://phabricator.services.mozilla.com/D24025

--HG--
extra : moz-landing-system : lando
2019-04-11 16:27:12 +00:00
Mike Hommey d452755d02 Bug 1542996 - Remove duplicate component registration. r=kmag
Bug 1478124 and bug 1524687 converted many things to static xpcom
component registration, but somehow left the corresponding C++
initialization.

Differential Revision: https://phabricator.services.mozilla.com/D26697

--HG--
extra : moz-landing-system : lando
2019-04-09 18:58:49 +00:00
Mike Hommey 071a2fe984 Bug 1541792 - Replace linker magic with manual component registration. r=froydnj
Before bug 938437, we had a rather large and error-prone
nsStaticXULComponents.cpp used to register all modules. That was
replaced with clever use of the linker, which allowed to avoid the mess
that maintaining that file was.

Fast forward to now, where after bug 1524687 and other work that
preceded it, we have a much smaller number of remaining static xpcom
components, registered via this linker hack, and don't expect to add
any new ones. The list should eventually go down to zero.

Within that context, it seems to be the right time to get rid of the
magic, and with it the problems it causes on its own.

Some of those components could probably be trivially be converted to
static registration via .conf files, but I didn't want to deal with the
possible need to increase the number of dummy modules in XPCOMInit.cpp.
They can still be converted as a followup.

Differential Revision: https://phabricator.services.mozilla.com/D26076

--HG--
extra : moz-landing-system : lando
2019-04-05 02:30:56 +00:00
Sylvestre Ledru 03c8e8c2dd Bug 1519636 - clang-format-8: Reformat recent changes to the Google coding style r=Ehsan
clang-format-8 upstream had some improvements wrt macros
See: https://reviews.llvm.org/D33440
This is why the diff is bigger than usual

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D26098

--HG--
extra : moz-landing-system : lando
2019-04-05 21:41:42 +00:00
Bogdan Tara 621ec01c2c Merge inbound to mozilla-central. a=merge 2019-04-05 19:18:43 +03:00
Ian Moody 3e10462c9e Bug 1541024 - parser/ automated ESLint no-throw-literal fixes. r=hsivonen
Result of running:
$ mach eslint -funix parser/ | sed -Ee 's/:.+//' - | xargs sed -E \
    -e 's/throw ((["`])[^"]+\2);/throw new Error(\1);/g' \
    -e 's/throw ((["`])[^"]+\2 \+ [^ ";]+);/throw new Error(\1);/g' \
    -e 's/throw \(/throw new Error(/g' -i

Differential Revision: https://phabricator.services.mozilla.com/D25757

--HG--
extra : moz-landing-system : lando
2019-04-05 11:31:01 +00:00
Csoregi Natalia ba58e936bd Backed out changeset 4ad80127f89f (bug 1519636) for bustage on MarkupMap.h and nsAccessibilityService.cpp. CLOSED TREE 2019-04-05 09:48:19 +03:00
Sylvestre Ledru d1c1878603 Bug 1519636 - clang-format-8: Reformat recent changes to the Google coding style r=Ehsan
clang-format-8 upstream had some improvements wrt macros
See: https://reviews.llvm.org/D33440
This is why the diff is bigger than usual

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D26098

--HG--
extra : moz-landing-system : lando
2019-04-04 21:36:16 +00:00
Brindusan Cristian 655cd99db5 Backed out 2 changesets (bug 1540170) for xpcshell failures at test_sanitizer.js. CLOSED TREE
Backed out changeset a13bf582f195 (bug 1540170)
Backed out changeset b5ed3294a9d7 (bug 1540170)
2019-04-05 06:23:23 +03:00
Gijs Kruitbosch 8833331cd2 Bug 1540170 - release assert if something tries to start the history service before profile startup, r=mak
Differential Revision: https://phabricator.services.mozilla.com/D24910

--HG--
extra : moz-landing-system : lando
2019-04-04 23:05:23 +00:00
Narcis Beleuzu 24dbe577a5 Backed out changeset 389b6bbd76db (bug 1519636) for bustages on MarkupMap.h . CLOSED TREE 2019-04-05 00:27:56 +03:00
Sylvestre Ledru 399dbd28fe Bug 1519636 - clang-format-8: Reformat recent changes to the Google coding style r=Ehsan
clang-format-8 upstream had some improvements wrt macros
See: https://reviews.llvm.org/D33440
This is why the diff is bigger than usual

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D26098

--HG--
extra : moz-landing-system : lando
2019-04-04 20:12:23 +00:00
Gijs Kruitbosch 3e756a4e5d Bug 1540170 - release assert if something tries to start the history service before profile startup, r=mak
Differential Revision: https://phabricator.services.mozilla.com/D24910

--HG--
extra : rebase_source : c21f2cceca996630f4e0d8442c0282e361073505
2019-03-26 15:17:42 +00:00
Masayuki Nakano 5e41233499 Bug 1540990 - Get rid of unnecessary nsIPresShell.h inclusions r=emilio
A lot of files include `nsIPresShell.h` even though currently they don't
need it.  This patch removes the unnecessary inclusions.

Differential Revision: https://phabricator.services.mozilla.com/D25744

--HG--
extra : moz-landing-system : lando
2019-04-04 00:19:48 +00:00
Razvan Maries 1cd564b971 Backed out changeset 3b94c20ba873 (bug 1540990) for build bustages. CLOSED TREE 2019-04-04 02:44:00 +03:00
Masayuki Nakano b2bba953cc Bug 1540990 - Get rid of unnecessary nsIPresShell.h inclusions r=emilio
A lot of files include `nsIPresShell.h` even though currently they don't
need it.  This patch removes the unnecessary inclusions.

Differential Revision: https://phabricator.services.mozilla.com/D25744

--HG--
extra : moz-landing-system : lando
2019-04-03 23:29:38 +00:00
Masayuki Nakano e705b3211c Bug 1540015 - part 1: Make Document.h stop including nsIPresShell.h r=smaug
If `Document::GetShell()` returns `PresShell*` rather than `nsIPresShell`, it's
a good step to deCOMTaminate `PresShell`.

This patch makes `Document.h` stop including `nsIPresShell.h` since
`nsIPresShell.h` includes `Document.h` indirectly and that causes bustage
when we make `Document::GetShell()` return `PresShell*`.

Differential Revision: https://phabricator.services.mozilla.com/D25332

--HG--
extra : moz-landing-system : lando
2019-03-29 15:11:04 +00:00
Dorel Luca 5a0fa68b78 Backed out 3 changesets (bug 1540015) for build bustage. CLOSED TREE
Backed out changeset 7b71c9da0214 (bug 1540015)
Backed out changeset 5723ddbc5c44 (bug 1540015)
Backed out changeset 9561d2c36fa5 (bug 1540015)
2019-03-29 16:14:26 +02:00
Masayuki Nakano 854606257b Bug 1540015 - part 1: Make Document.h stop including nsIPresShell.h r=smaug
If `Document::GetShell()` returns `PresShell*` rather than `nsIPresShell`, it's
a good step to deCOMTaminate `PresShell`.

This patch makes `Document.h` stop including `nsIPresShell.h` since
`nsIPresShell.h` includes `Document.h` indirectly and that causes bustage
when we make `Document::GetShell()` return `PresShell*`.

Differential Revision: https://phabricator.services.mozilla.com/D25332

--HG--
extra : moz-landing-system : lando
2019-03-29 12:12:20 +00:00
Mark Banner dba6983e75 Bug 1415265 - Remove now unnecessary .eslintrc.js files or entries. r=mossop
Differential Revision: https://phabricator.services.mozilla.com/D23850

--HG--
extra : moz-landing-system : lando
2019-03-28 09:38:14 +00:00
Henri Sivonen c798ef580c Bug 1534346 - Mark malformed SVG scripts as malformed for real. r=alchen
Differential Revision: https://phabricator.services.mozilla.com/D24347

--HG--
extra : moz-landing-system : lando
2019-03-21 20:39:22 +00:00
Sylvestre Ledru 4aa92e3091 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D22514
2019-03-13 10:19:06 +01:00
Brendan Dahl 7ebaf1cd2b Bug 1527977 - Share XUL prototype cache with XUL and XHTML. r=smaug
Create a new parser (PrototypeDocumentParser) and content sink
(PrototypeDocumentContentSink) that can be used by both XUL and XHTML.

The new parser moves the code from XULDocument that handles creating and
loading a nsXULPrototypeDocument from either the cache or the source
file. Once the parser has finished loading the prototype it notifies the
content sink. The parser is largely a stub and would be better suited
for use as a nsBaseParser, but nsHTMLDocument unfortunately needs an
nsIParser.

The new content sink has the XULDocument code responsible for the
prototype traversal that creates the DOM (XULDocument::ResumeWalk and
friends) and fires off various events.

To unify XUL and XHTML, the XHTML readystate event sequence is used in
XUL. However, the layout path of XHTML loaded from the prototype cache
more closely follows XUL, where frame initializers and layout don't
start until the entire DOM is built.

Differential Revision: https://phabricator.services.mozilla.com/D21236

--HG--
rename : dom/xul/XULDocument.cpp => dom/prototype/PrototypeDocumentContentSink.cpp
rename : parser/moz.build => dom/prototype/moz.build
rename : parser/moz.build => parser/prototype/moz.build
extra : moz-landing-system : lando
2019-03-09 01:00:23 +00:00
Ryan Hunt 3091198ef3 Bug 1523969 part 20 - Move method definition inline comments to new line in 'parser/'. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D21121

--HG--
extra : rebase_source : 0d70bb459affb4887f888a8c9395c6be947e5f75
2019-02-25 16:11:34 -06:00
Boris Zbarsky 9c5da5f234 Bug 1489308 part 9. Remove now-unused wyciwyg bits. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D17327

--HG--
rename : dom/html/test/browser_refresh_wyciwyg_url.js => dom/html/test/browser_refresh_after_document_write.js
rename : dom/html/test/file_refresh_wyciwyg_url.html => dom/html/test/file_refresh_after_document_write.html
extra : moz-landing-system : lando
2019-02-28 01:09:48 +00:00
Boris Zbarsky 2e5c884144 Bug 1489308 part 5. Align the work we do on document.open with the spec. r=mccr8,smaug
The main behavior changes are:

1) We no longer create a new Window when doing document.open().  We use the
same Window but remove all the event listeners on it and on the existing DOM
tree before removing the document's existing kids.

2) We no longer create a new session history entry.  The existing one always
gets replaced instead.

3) We now support document.open on documents that are not in a Window.

The reasons for the various test changes are as follows:

The change to browser_modifiedclick_inherit_principal.js is because we no
longer set the docshell to a wyciwyg URL when document.open() happens and the
test was depending on that to terminate.

browser_wyciwyg_urlbarCopying.js is being removed because it's trying to test
wyciwyg URIs, which no longer exist.

The changes in docshell/test/navigation are because document.open() no longer
affects session history.  One of the tests was testing the interactions there
and is being removed; another is being repurposed to just test that
document.open() does not affect history.length.

The change to test_x-frame-options.html is because document.open() now removes
event listeners on the window, which it didn't use to do (and in the specific
case in this test reused the existing inner too, so the listener was still
around in practice).  The new behavior matches other browsers.

The removal of test_bug172261.html is because document.open() no longer affects
session history, so you can't go back across it or forward to the "opened"
state, so the situation that test is trying to test no longer exists.

The changes to test_bug255820.html are because reloading a document after
document.open() will now just load the URL of the document that was the entry
document for the open() call, not reload the written content.  So there's not
much point testing reload behavior, and in this test it was just reloading the
toplevel test file inside the frames.

The change to test_bug346659.html is because now we no longer create a new
Window on document.open().

The change to test_bug1232829.html is because document.open() (implicit in this
test) no longer adds history entries, so the back() was just leaving the test
page instead of going back across the document.open().  The test is a
crashtest in practice, so might still be testing something useful about how
document.open() interacts with animations.

The change to test_bug715739.html is because the URL of the document after
document.open() is now the URL of the entry document, not a wyciwyg URL, so
reload() has different behavior than it used to.

The change to test_bug329869.html is because now when we go back we're
reloading the original document we had, not doing a wyciwyg load, and the
security info now doesn't include the untrusted script.

The changes to the wpt expectations are removing a bunch of expected failures
now that we pass those tests and disabling some tests that are fundamentally
racy and hence fail randomly.  The latter all have github issues filed for the
test problem.

The change to testing/web-platform/tests/common/object-association.js is fixing
tests that were not matching the spec (and were failing in other browsers).

The change to parser-uses-registry-of-owner-document.html is fixing tests that
were not matching the spec (and were failing in other browsers).

The change to document-write.tentative.html is because the test was buggy: it
was using the same iframe element for all its tests and racing loads from some
tests against API calls from other tests, etc.  It's a wonder it ever managed
to pass, independent of these patches (and in fact it doesn't pass according to
wpt.fyi data, even in Firefox).

The changes in html/browsers/history/the-history-interface are because
document.open() no longer adds history entries.  The test was failing in all
other browsers for the same reason.

The changes in html/browsers/history/the-location-interface are because
reloading a document.open()-created thing now loads the URL of the page that
was the entry document for the open() call.  The test was failing in all other
browsers.

The change to reload_document_open_write.html is because we now reload the url
of the document that entered the script that called open() when we reload, not
the written content.  Other browsers were failing this test too; Gecko with
the old document.open implementation was the only one that passed.

The change to http-refresh.py is to fix a test bug: it was not returning a
Content-Type header, so we were putting up helper app dialogs, etc.

The change to test_ext_contentscript.js is because we no create a new global
for document.open() calls.  Kris Maglione OKed this part.

Differential Revision: https://phabricator.services.mozilla.com/D17323

--HG--
extra : moz-landing-system : lando
2019-02-27 23:24:48 +00:00
Jonathan Kingston f6680698bd Bug 1525319 - Removing context from OnDataAvailable r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D20881

--HG--
extra : moz-landing-system : lando
2019-02-27 23:42:27 +00:00
Jonathan Kingston c4853316e7 Bug 1525319 - Removing context from OnStopRequest r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D20770

--HG--
extra : moz-landing-system : lando
2019-02-27 23:41:31 +00:00
Jonathan Kingston f7e35ae39e Bug 1525319 - Removing context from OnStartRequest r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D20769

--HG--
extra : moz-landing-system : lando
2019-02-27 23:41:04 +00:00
Dorel Luca 4a4dcd57fa Backed out 4 changesets (bug 1525319) for Android failures in dom/base/test/test_progress_events_for_gzip_data.html
Backed out changeset b73f033efb41 (bug 1525319)
Backed out changeset 1d318d5c6b98 (bug 1525319)
Backed out changeset 6d73418988d4 (bug 1525319)
Backed out changeset 84ca79bd2dc3 (bug 1525319)
2019-02-25 04:06:11 +02:00
Jonathan Kingston 63ab2bd8aa Bug 1525319 - Removing context from OnDataAvailable r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D20881

--HG--
extra : moz-landing-system : lando
2019-02-24 20:27:55 +00:00
Jonathan Kingston 332531fa9c Bug 1525319 - Removing context from OnStopRequest r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D20770

--HG--
extra : moz-landing-system : lando
2019-02-24 20:26:59 +00:00
Jonathan Kingston 2441197975 Bug 1525319 - Removing context from OnStartRequest r=valentin
Differential Revision: https://phabricator.services.mozilla.com/D20769

--HG--
extra : moz-landing-system : lando
2019-02-24 20:26:16 +00:00
Kris Maglione b2f85650a1 Bug 1524687: Part 12 - Convert everything else to static registration. r=erahm
--HG--
extra : source : 625f71135038f79c075f758e316fbb00097c9a18
extra : intermediate-source : 7a1ef487a9e74d66b112034051e49b77023860b8
extra : histedit_source : 88d19dbee4a99faa191e49e2847c4c59aba05b0c%2C5ee702f97153152d31124e0c5f3e8318cbeb3195
2019-01-29 16:03:41 -08:00
arthur.iakab 470dbf03b6 Backed out 5 changesets (bug 1524687) for causing build bustages on platform.h CLOSED TREE
Backed out changeset 0f06a6b51bfe (bug 1524687)
Backed out changeset 7a1ef487a9e7 (bug 1524687)
Backed out changeset accad7b4cbc7 (bug 1524687)
Backed out changeset eb33f7e6467c (bug 1524687)
Backed out changeset 86cf09db340b (bug 1524687)
2019-02-21 02:04:02 +02:00
Kris Maglione 95c0cf7aa9 Bug 1524687: Part 12 - Convert everything else to static registration. r=erahm
--HG--
extra : rebase_source : ccc1b4f8559152237e523b67ea76e2b406c1cb11
extra : intermediate-source : e8ad5619116c31fc4d38e0e789ddb9b5d2a5bb25
extra : source : 625f71135038f79c075f758e316fbb00097c9a18
2019-01-29 16:03:41 -08:00
Jonathan Kingston 3421b8fcff Bug 1520868 - Replacing AsyncOpen2 with AsyncOpen always r=valentin
Replacing js and text occurences of asyncOpen2
Replacing open2 with open

Differential Revision: https://phabricator.services.mozilla.com/D16885

--HG--
rename : layout/style/test/test_asyncopen2.html => layout/style/test/test_asyncopen.html
extra : moz-landing-system : lando
2019-02-12 16:08:25 +00:00
Mike Hommey e6ab5d959a Bug 1516642 - Add a function declaration for arc4random_buf in expat. r=peterv
The function has been in bionic (Android's libc since the first commit
in the upstream repository), but it's not been in stdlib.h until
recently. As it happens, we have a similar declaration in
xpcom/base/nsUUIDGenerator.cpp.

Differential Revision: https://phabricator.services.mozilla.com/D19120

--HG--
extra : moz-landing-system : lando
2019-02-08 13:48:36 +00:00
Daniel Varga 007e1e4a2f Merge mozilla-inbound to mozilla-central. a=merge 2019-01-30 23:54:54 +02:00
Myk Melez 25349d2601 Bug 1518283 - prohibit blank lines at the beginning and end of blocks (eslint padded-blocks) r=mossop,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D17526

--HG--
extra : moz-landing-system : lando
2019-01-30 17:26:25 +00:00
Zibi Braniecki 51cb6c2749 Bug 1518252 - Block layout on Fluent. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D17334

--HG--
extra : moz-landing-system : lando
2019-01-25 23:14:03 +00:00
Cosmin Sabou d4afc5310c Backed out 2 changesets (bug 1518252) for frequent clipboard failures on browser_jsterm_middle_click_paste.
Backed out changeset b6f80451898e (bug 1518252)
Backed out changeset 06114c66901f (bug 1518252)

--HG--
extra : rebase_source : 795b3a29b1344ce224207c4034f13d3d7f1a5c53
2019-01-24 02:50:54 +02:00
Zibi Braniecki 5e38c8a5a5 Bug 1518252 - Block layout on Fluent. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D17334

--HG--
extra : moz-landing-system : lando
2019-01-23 21:29:15 +00:00
Olli Pettay 8eead4ff04 Bug 1521931 - Parser should yield if there is a pending high priority event before first contentful paint, r=hsivonen
--HG--
extra : rebase_source : 6e7de3f0bfc98ec991bd4c003ed005b4ea2ebf07
2019-01-30 15:35:02 +02:00
Jon Coppeard a96229ddb3 Bug 1512749 - Convert JS::gcreason::Reason to enum class JS:GCReason r=jonco r=mccr8 2019-01-21 13:09:12 +00:00
Margareta Eliza Balazs 9dda825205 Merge mozilla-central to inbound. a=merge CLOSED TREE 2019-01-18 12:31:59 +02:00
Ehsan Akhgari e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
Boris Zbarsky eb529dfa42 Bug 1520812. Remove bogus assertion in nsExpatDriver::HandleError. r=hsivonen
Any time we stop a load of an XML document before we've gotten all the data,
we'll end up in this code with mSink null, because nsParser::Terminate ends up
calling nsExpatDriver::DidBuildModel which nulls out mSink, and not getting all
the data means the XML won't be well-formed.

Differential Revision: https://phabricator.services.mozilla.com/D16856

--HG--
extra : moz-landing-system : lando
2019-01-17 15:34:15 +00:00
Sylvestre Ledru 47a5dd1fb8 Bug 1519636 - Reformat everything to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D16388

--HG--
extra : moz-landing-system : lando
2019-01-16 08:50:07 +00:00
Henri Sivonen 34559b2b59 Bug 256180 parser part - Insert elements as siblings instead of children at the Blink-defined magic depth for compatibility. r=smaug.
MozReview-Commit-ID: K8fgv3rgklt
2019-01-11 09:44:09 +02:00
Andreea Pavel f5a1a0f098 Backed out 5 changesets (bug 256180) for failing win xpcshell at xpcshell.ini:toolkit/mozapps/extensions/test/xpcshell/test_temporary.js on a CLOSED TREE
Backed out changeset e85e41f84971 (bug 256180)
Backed out changeset 125ebcfac58d (bug 256180)
Backed out changeset bc2e0a89d88e (bug 256180)
Backed out changeset b696df615c8b (bug 256180)
Backed out changeset 2d69841d2eb7 (bug 256180)
2019-01-08 20:35:31 +02:00
Daniel Varga 599bfc410a Merge mozilla-central to mozilla-inbound. a=merge on a CLOSED TREE
--HG--
rename : browser/components/pocket/locale/en-US/pocket.properties => browser/locales/en-US/chrome/browser/pocket.properties
rename : devtools/client/aboutdebugging-new/test/browser/head-addons-script.js => devtools/client/aboutdebugging-new/test/browser/helper-addons.js
rename : devtools/client/aboutdebugging-new/test/browser/debug-target-pane_collapsibilities_head.js => devtools/client/aboutdebugging-new/test/browser/helper-collapsibilities.js
rename : devtools/client/aboutdebugging-new/test/browser/head-mocks.js => devtools/client/aboutdebugging-new/test/browser/helper-mocks.js
rename : devtools/client/aboutdebugging-new/test/browser/head-serviceworker.js => devtools/client/aboutdebugging-new/test/browser/helper-serviceworker.js
rename : devtools/client/aboutdebugging-new/test/browser/mocks/head-client-wrapper-mock.js => devtools/client/aboutdebugging-new/test/browser/mocks/helper-client-wrapper-mock.js
rename : devtools/client/aboutdebugging-new/test/browser/mocks/head-runtime-client-factory-mock.js => devtools/client/aboutdebugging-new/test/browser/mocks/helper-runtime-client-factory-mock.js
rename : devtools/client/aboutdebugging-new/test/browser/mocks/head-usb-runtimes-mock.js => devtools/client/aboutdebugging-new/test/browser/mocks/helper-usb-runtimes-mock.js
rename : dom/base/nsIdentifierMapEntry.h => dom/base/IdentifierMapEntry.h
extra : rebase_source : 0d517ceff0f11aadfa88634e773b3436ad48a8e6
2019-01-08 18:35:10 +02:00
Henri Sivonen 7fdbc91b91 Bug 256180 parser part - Insert elements as siblings instead of children at the Blink-defined magic depth for compatibility. r=smaug.
MozReview-Commit-ID: K8fgv3rgklt
2019-01-08 18:08:37 +02:00
Henri Sivonen 063ff34a92 Bug 1447707 - Remove the XPIDL SAX interface to the XML parser. r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D14724

--HG--
extra : moz-landing-system : lando
2018-12-19 16:49:31 +00:00
Emilio Cobos Álvarez d2ed260822 Bug 1517241 - Rename nsIDocument to mozilla::dom::Document. r=smaug
Summary: Really sorry for the size of the patch. It's mostly automatic
s/nsIDocument/Document/ but I had to fix up in a bunch of places manually to
add the right namespacing and such.

Overall it's not a very interesting patch I think.

nsDocument.cpp turns into Document.cpp, nsIDocument.h into Document.h and
nsIDocumentInlines.h into DocumentInlines.h.

I also changed a bunch of nsCOMPtr usage to RefPtr, but not all of it.

While fixing up some of the bits I also removed some unneeded OwnerDoc() null
checks and such, but I didn't do anything riskier than that.
2019-01-03 17:48:33 +01:00
Emilio Cobos Álvarez f131713362 Bug 1516366 - Move base classes from nsDocument to nsIDocument. r=smaug
This is a big step in order to merge both.

Also allows to remove some very silly casts, though it causes us to add some
ToSupports around to deal with ambiguity of casts from nsIDocument to
nsISupports, and add a dummy nsISupports implementation that will go away later
in the series.

Differential Revision: https://phabricator.services.mozilla.com/D15352
2018-12-29 20:41:28 +01:00
Sylvestre Ledru cccdda3c2a Bug 1516555 - Reformat everything to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D15426

--HG--
extra : moz-landing-system : lando
2018-12-28 15:48:06 +00:00
Peter Van der Beken eb86fefb02 Bug 1374012 - Update to Expat 2.2.1. Part 18: various miscellaneous changes. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14457

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:26 +00:00
Peter Van der Beken 7a603b28e7 Bug 1374012 - Update to Expat 2.2.1. Part 17: add/change APIs that are not used in Gecko. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14456

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:25 +00:00
Peter Van der Beken 0e027c70be Bug 1374012 - Update to Expat 2.2.1. Part 16: fix some issues with various compilers. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14455

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:24 +00:00
Peter Van der Beken cf5d21461b Bug 1374012 - Update to Expat 2.2.1. Part 15: ifdef some constants so they are only defined when used. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14454

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:23 +00:00
Peter Van der Beken e88d24ea11 Bug 1374012 - Update to Expat 2.2.1. Part 14: Annotate memory allocators for GCC. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14453

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:22 +00:00
Peter Van der Beken 18fcb94d9e Bug 1374012 - Update to Expat 2.2.1. Part 13: Tidy up attribute prefix bindings on error. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14452

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:21 +00:00
Peter Van der Beken 5793b635bc Bug 1374012 - Update to Expat 2.2.1. Part 12: Address warning "missing initializer for field". r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14451

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:20 +00:00
Peter Van der Beken a3204ff408 Bug 1374012 - Update to Expat 2.2.1. Part 11: Changes to defines for various compilers. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14450

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:19 +00:00
Peter Van der Beken f652ec9604 Bug 1374012 - Update to Expat 2.2.1. Part 10: Take into account that CHAR_MATCHES may read >1 bytes. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14449

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:18 +00:00
Peter Van der Beken e0c4b31e3c Bug 1374012 - Update to Expat 2.2.1. Part 9: Make XmlConvert return errors. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14448

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:17 +00:00
Peter Van der Beken 7afc61faae Bug 1374012 - Update to Expat 2.2.1. Part 8: Validate parser argument in various APIs. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14447

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:16 +00:00
Peter Van der Beken 90a42151df Bug 1374012 - Update to Expat 2.2.1. Part 7: Add __unused__ anotations. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14446

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:16 +00:00
Peter Van der Beken bebd150ad3 Bug 1374012 - Update to Expat 2.2.1. Part 6: Add XML_ATTR_INFO code which we don't enable. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14445

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:15 +00:00
Peter Van der Beken 6a0c98bfbf Bug 1374012 - Update to Expat 2.2.1. Part 5: Use ASCII_* instead of literal characters. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14444

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:14 +00:00
Peter Van der Beken cc52d0e9e6 Bug 1374012 - Update to Expat 2.2.1. Part 4: removing mainlined customisations and merge whitespace changes. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14443

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:13 +00:00
Peter Van der Beken 650f9e44c2 Bug 1374012 - Update to Expat 2.2.1. Part 3: Reject invalid DTD. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14442

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:12 +00:00
Peter Van der Beken 177f23f661 Bug 1374012 - Update to Expat 2.2.1. Part 2b: cherry-pick compilation fix from 2.2.2. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14441

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:11 +00:00
Peter Van der Beken 05221a9c4c Bug 1374012 - Update to Expat 2.2.1. Part 2a: Better hashing. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14440

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:11 +00:00
Peter Van der Beken f9a10464ec Bug 1374012 - Update to Expat 2.2.1. Part 1: More correct calculations. r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D14439

--HG--
extra : moz-landing-system : lando
2018-12-27 15:13:10 +00:00
Margareta Eliza Balazs 7ef930fffa Backed out changeset 2eab9d9bd89e (bug 1514655) for geckoview-junit perma failures NavigationDelegateTest.loadData_noMimeType CLOSED TREE 2018-12-21 15:34:27 +02:00
Emilio Cobos Álvarez 5a57093928 Bug 1514655 - Always wrap plain text documents. r=bzbarsky
This matches other UAs.

Differential Revision: https://phabricator.services.mozilla.com/D14848

--HG--
extra : moz-landing-system : lando
2018-12-18 14:48:31 +00:00
Henri Sivonen feff447597 Bug 1515066 - Mark SVG script without an end tag malformed. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D15090

--HG--
extra : moz-landing-system : lando
2018-12-20 18:20:04 +00:00
Brindusan Cristian df66fd18a1 Merge inbound to mozilla-central. a=merge 2018-12-18 19:34:11 +02:00
Henri Sivonen 9405805403 Bug 1514728 - Fix bogus subspanning when sniffing a local file with more than 4 MB of ASCII. r=emk. 2018-12-18 08:45:29 +02:00
Henri Sivonen 64e1d8a0f5 Bug 1510114. r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D13679

--HG--
extra : moz-landing-system : lando
2018-12-12 14:24:31 +00:00
Jonathan Kingston c5d29c382e Bug 903372 - Remove xml:base from parser. r=hsivonen 2018-12-13 15:47:01 +00:00
Mark Banner 8fc9eab7b3 Bug 1503674 - Remove now unused nsIScriptableUnescapeHTML.idl. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D14680

--HG--
extra : moz-landing-system : lando
2018-12-17 09:33:28 +00:00
Henri Sivonen acfba8e927 Bug 1469580 - Ignore charset= in <meta content> if followed by unmatched quote. r=mrbkap
Differential Revision: https://phabricator.services.mozilla.com/D14410

--HG--
extra : moz-landing-system : lando
2018-12-14 17:53:59 +00:00
Coroiu Cristina 3e33183ebf Backed out changeset a145a897c94c (bug 1469580) for lin failure at /builds/worker/checkouts/gecko/tools/lint/wpt.yml 2018-12-14 12:33:15 +02:00
Henri Sivonen 20f693b781 Bug 1469580 - Ignore charset= in <meta content> if followed by unmatched quote. r=mrbkap
Differential Revision: https://phabricator.services.mozilla.com/D14410

--HG--
extra : moz-landing-system : lando
2018-12-13 18:48:09 +00:00
Henri Sivonen f4bcccb098 Bug 1513513 - Drop the file: URL UTF-8 sniffing limit from 50 MB to 4 MB. r=emk. 2018-12-12 16:10:28 +02:00
Henri Sivonen 61285e86b3 Bug 977540 - Avoid running Japanese, Russian and Ukrainian detectors on domains associated with different encoding legacies. r=emk. 2018-12-12 09:51:52 +02:00
Henri Sivonen 69ad08c987 Bug 1071816 - Support loading unlabeled/BOMless UTF-8 text/html and text/plain files from file: URLs. r=emk. 2018-12-11 10:36:46 +02:00
Henri Sivonen c58ccc7e2b Bug 1512155 - Introduce a movable type that combines mozilla::UniquePtr<T[]> and its length. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D13795

--HG--
extra : moz-landing-system : lando
2018-12-07 08:28:08 +00:00
Henri Sivonen 236e52e49e Bug 1511972 - Clean up byte buffer representation in method signatures in nsHtml5StreamParser. r=mrbkap
Differential Revision: https://phabricator.services.mozilla.com/D13732

--HG--
extra : moz-landing-system : lando
2018-12-06 18:59:56 +00:00
reimu f4794a2bfb Bug 1501931 - Enable ESLint for parser/ (manual fixes) r=Standard8,mrbkap
Depends on D11920

Differential Revision: https://phabricator.services.mozilla.com/D11921

--HG--
extra : moz-landing-system : lando
2018-12-06 20:30:32 +00:00
reimu 4819e4a0ee Bug 1501931 - Enable ESLint for parser/ (automatic fixes) r=Standard8,mrbkap
Differential Revision: https://phabricator.services.mozilla.com/D11920

--HG--
extra : moz-landing-system : lando
2018-12-06 20:34:29 +00:00
Tooru Fujisawa 7983faeb5d Bug 1511393 - Use c-basic-offset: 2 in Emacs mode line for C/C++ code. r=nbp 2018-12-01 04:52:05 +09:00
Benjamin Bouvier a7f1d173a0 Bug 1511383: Update vim modelines after clang-format; r=sylvestre
- modify line wrap up to 80 chars; (tw=80)
- modify size of tab to 2 chars everywhere; (sts=2, sw=2)

--HG--
extra : rebase_source : 7eedce0311b340c9a5a1265dc42d3121cc0f32a0
extra : amend_source : 9cb4ffdd5005f5c4c14172390dd00b04b2066cd7
2018-11-30 16:39:55 +01:00
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Andreea Pavel 0c29092e41 Backed out 2 changesets (bug 903372) for multiple failures on a CLOSED TREE
Backed out changeset bf919773f9d1 (bug 903372)
Backed out changeset 6562c2392ac9 (bug 903372)
2018-11-30 04:16:21 +02:00
Jonathan Kingston 7c7d460eaa Bug 903372 - Remove xml:base from parser. r=hsivonen 2018-10-21 12:55:44 +01:00
Ehsan Akhgari 490e611801 Bug 1508472 - Part 5: Fifth batch of comment fix-ups in preparation for the tree reformat r=sylvestre
This is a best effort attempt at ensuring that the adverse impact of
reformatting the entire tree over the comments would be minimal. I've used a
combination of strategies including disabling of formatting, some manual
formatting and some changes to formatting to work around some clang-format
limitations.

Differential Revision: https://phabricator.services.mozilla.com/D13371

--HG--
extra : moz-landing-system : lando
2018-11-29 10:30:46 +00:00
Gabriele Svelto 19e52bebd4 Bug 1510582 - Remove useless inclusions of Services.h r=erahm
Differential Revision: https://phabricator.services.mozilla.com/D13240

--HG--
extra : moz-landing-system : lando
2018-11-28 17:25:23 +00:00
Thomas Nguyen 6d1ae50d62 Bug 1460920 - Part 1 - Speculative loading script should take referrerpolicy attribute in script element into account r=hsivonen
Referrerpolicy attribute should be taken with high priority order than
mSpeculationReferrerPolicy

Differential Revision: https://phabricator.services.mozilla.com/D11636

--HG--
extra : moz-landing-system : lando
2018-11-19 09:39:16 +00:00
Timothy Guan-tin Chien af2973ef61 Bug 1503019 - Part II, Remove dom.webcomponents.customelements.enabled pref r=smaug
This patch removes the following functions:

* nsContentUtils::IsCustomElementsEnabled()
* CustomElementRegistry::IsCustomElementEnabled(JSContext* aCx, JSObject* aObject)
* CustomElementRegistry::IsCustomElementEnabled(nsIDocument* aDoc)

and all references of the pref.

Depends on D11183

Differential Revision: https://phabricator.services.mozilla.com/D11249

--HG--
extra : moz-landing-system : lando
2018-11-15 06:52:01 +00:00
Andreea Pavel d51566f085 Backed out 2 changesets (bug 1503019) for failing crashtests at dom/base/crashtests/1505811.html on a CLOSED TREE
Backed out changeset 06b12fd41ff1 (bug 1503019)
Backed out changeset 7b845eac9dd7 (bug 1503019)
2018-11-15 01:52:30 +02:00
Timothy Guan-tin Chien c69315234b Bug 1503019 - Part II, Remove dom.webcomponents.customelements.enabled pref r=smaug
This patch removes the following functions:

* nsContentUtils::IsCustomElementsEnabled()
* CustomElementRegistry::IsCustomElementEnabled(JSContext* aCx, JSObject* aObject)
* CustomElementRegistry::IsCustomElementEnabled(nsIDocument* aDoc)

and all references of the pref.

Depends on D11183

Differential Revision: https://phabricator.services.mozilla.com/D11249

--HG--
extra : moz-landing-system : lando
2018-11-14 19:37:42 +00:00
Brian Grinstead 35b0511c9a Bug 1425874 - Implement HTMLMarqueeElement r=bzbarsky
This adds a new class for the marquee tag, instead of overloading HTMLDivElement.
It removes some of the XBL that was used to expose properties to web content.

Differential Revision: https://phabricator.services.mozilla.com/D3824

--HG--
extra : moz-landing-system : lando
2018-11-14 05:29:11 +00:00
Emilio Cobos Álvarez fe445c3367 Bug 1506133 - More HTML parser cleanup post bug 1392185. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D11480

--HG--
extra : moz-landing-system : lando
2018-11-12 14:37:09 +00:00
Emilio Cobos Álvarez 03ce7b0699 Bug 1392185 - Remove dynamic HTML5 atoms. r=njn,hsivonen
This is a rebase + manual refcounting on some places, + cleanup of the original
patch in the bug.

Co-authored-by: Nicholas Nethercote <nnethercote@mozilla.com>

Differential Revision: https://phabricator.services.mozilla.com/D11035
2018-11-09 14:45:30 +01:00
Emilio Cobos Álvarez ed9deed211 Bug 1392185 - Remove dead code from nsHtml5ArrayCopy.h. r=hsivonen
Drive-by cleanup while I audited atom usage from the parser.

Differential Revision: https://phabricator.services.mozilla.com/D11033
2018-11-09 14:45:29 +01:00
Jonathan Kingston 0d35be67e4 Bug 1466449 - Update Tokenizer.java and StackNode.java to initialize properties. r=hsivonen 2018-11-09 14:20:19 +01:00
Henri Sivonen 8c8503b03f Bug 1466449 addendum - Turn jArray from a struct to class and make it have a constructor from nullptr. r=smaug.
Simple adding a constructor from nullptr did not compile without turning
jArray all the way to a class instead of struct.
2018-11-09 14:20:18 +01:00
Henri Sivonen 3a3e5d3765 Bug 1364399 follow-up - Test cases and clarifying comment. r=smaug.
MozReview-Commit-ID: KoHMiyIVb8f
2018-11-07 12:54:42 +02:00
Ehsan Akhgari 6f7b03e600 Bug 1504574 - Remove the XPCOM registration for nsDocumentEncoder; r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D10856
2018-11-05 23:16:04 -05:00
Mark Banner a26105ff45 Bug 1501662 - Add more .eslintrc.js files for test directories (dom, modules, netwerk and parser). r=mossop
Differential Revision: https://phabricator.services.mozilla.com/D9661

--HG--
extra : moz-landing-system : lando
2018-10-24 19:11:17 +00:00
Jonathan Kingston 580c9a51e4 Bug 1483458 - Change HTML parser to look at .py Atom files. r=hsivonen,heycam
--HG--
extra : amend_source : 9285251fc49d4f56b67557ef77e163d6acbc2b1e
2018-10-17 20:40:37 +01:00
Nathan Froyd 7d5d1b760a Bug 1499727 - make nsHtml5StreamParser timers slightly more efficient; r=hsivonen
Instead of creating a timer and then setting the timer's target, we can
determine the timer's target and pass it in directly when the timer is
created.  This reordering of steps is slightly more efficient, since
SetTarget() is both a virtual call and requires locking, both of which
can be skipped if we know the target at timer creation time.
2018-10-17 19:57:36 -04:00
Jeff Walden 73790f54e4 Bug 1493441 - Allow ScriptSource to store UTF-8 script data in addition to UTF-16 script data (but don't create any UTF-8-backed ScriptSources yet). r=tcampbell 2018-09-29 17:28:31 -04:00
Nathan Froyd e7b3b3140d Bug 1415980 - make hash keys movable and not copyable; r=erahm
Everything that goes in a PLDHashtable (and its derivatives, like
nsTHashtable) needs to inherit from PLDHashEntryHdr. But through a lack
of enforcement, copy constructors for these derived classes didn't
explicitly invoke the copy constructor for PLDHashEntryHdr (and the
compiler didn't invoke the copy constructor for us). Instead,
PLDHashTable explicitly copied around the bits that the copy constructor
would have.

The current setup has two problems:

1) Derived classes should be using move construction, not copy
   construction, since anything that's shuffling hash table keys/entries
   around will be using move construction.

2) Derived classes should take responsibility for transferring bits of
   superclass state around, and not rely on something else to handle that.

The second point is not a huge problem for PLDHashTable (PLDHashTable
only has to copy PLDHashEntryHdr's bits in a single place), but future
hash table implementations that might move entries around more
aggressively would have to insert compensation code all over the
place. Additionally, if moving entries is implemented via memcpy (which
is quite common), PLDHashTable copying around bits *again* is
inefficient.

Let's fix all these problems in one go, by:

1) Explicitly declaring the set of constructors that PLDHashEntryHdr
   implements (and does not implement). In particular, the copy
   constructor is deleted, so any derived classes that attempt to make
   themselves copyable will be detected at compile time: the compiler
   will complain that the superclass type is not copyable.

This change on its own will result in many compiler errors, so...

2) Change any derived classes to implement move constructors instead of
   copy constructors. Note that some of these move constructors are,
   strictly speaking, unnecessary, since the relevant classes are moved
   via memcpy in nsTHashtable and its derivatives.
2018-09-20 11:20:36 -04:00
Eric Rahm 2fb6934934 Bug 1492204 - Part 3: Remove references to char_iterator. r=froydnj
We can just use 'iterator' now that nsWritingIterator is gone.

--HG--
extra : rebase_source : 3f6fbafc9b57ce89afba581b224b3dc2295fa614
2018-09-18 12:05:23 -07:00
Eric Rahm 0c061732bd Bug 1492204 - Part 1: Stop using deprecated string writing iterators. r=froydnj
This switches over the few remaining usages of the deprecated
BeginWriting/EndWriting(iterator&) functions to the more standard
BeginWriting/EndWriting() functions.

--HG--
extra : rebase_source : 3c54621d4921eb45157ec4edce0b693bdd7f02d5
2018-09-18 09:44:57 -07:00
Henri Sivonen 89ca07c012 Bug 1487341 - Make Truncate(), SetLength() and Capacity() more efficient by keeping memcpying to the minimum. r=froydnj
MozReview-Commit-ID: 2LeRrWcN8vF

Differential Revision: https://phabricator.services.mozilla.com/D4661

--HG--
extra : moz-landing-system : lando
2018-09-17 09:45:02 +00:00
Ehsan Akhgari 15fb2860c4 Bug 1488659 - Part 1: Remove the XPCOM registrations for character detector classes; r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D5392
2018-09-10 07:59:42 -04:00
Mike Hommey 117e48720c Bug 1489363 - Replace some string.Assign* with AssignLiteral. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D5224

--HG--
extra : moz-landing-system : lando
2018-09-07 22:12:01 +00:00
Dave Townsend fd8d6b1590 Bug 1480465: Infer the namespace for custom elements at definition time by following the class hierarchy. r=smaug
When a custom element is defined we can check whether its class is an instance
of XULElement or HTMLElement and tag the defintion with a namespace accordingly.
This allows us to know the correct namespace for the custom element when
created.

Differential Revision: https://phabricator.services.mozilla.com/D2680

--HG--
extra : moz-landing-system : lando
2018-08-15 10:31:16 +00:00
Henri Sivonen 3edc601325 Bug 1402247 - Use encoding_rs for XPCOM string encoding conversions. r=Nika,erahm,froydnj.
Correctness improvements:

 * UTF errors are handled safely per spec instead of dangerously truncating
   strings.

 * There are fewer converter implementations.

Performance improvements:

 * The old code did exact buffer length math, which meant doing UTF math twice
   on each input string (once for length calculation and another time for
   conversion). Exact length math is more complicated when handling errors
   properly, which the old code didn't do. The new code does UTF math on the
   string content only once (when converting) but risks allocating more than
   once. There are heuristics in place to lower the probability of
   reallocation in cases where the double math avoidance isn't enough of a
   saving to absorb an allocation and memcpy.

 * Previously, in UTF-16 <-> UTF-8 conversions, an ASCII prefix was optimized
   but a single non-ASCII code point pessimized the rest of the string. The
   new code tries to get back on the fast ASCII path.

 * UTF-16 to Latin1 conversion guarantees less about handling of out-of-range
   input to eliminate an operation from the inner loop on x86/x86_64.

 * When assigning to a pre-existing string, the new code tries to reuse the
   old buffer instead of first releasing the old buffer and then allocating a
   new one.

 * When reallocating from the new code, the memcpy covers only the data that
   is part of the logical length of the old string instead of memcpying the
   whole capacity. (For old callers old excess memcpy behavior is preserved
   due to bogus callers. See bug 1472113.)

 * UTF-8 strings in XPConnect that are in the Latin1 range are passed to
   SpiderMonkey as Latin1.

New features:

 * Conversion between UTF-8 and Latin1 is added in order to enable faster
   future interop between Rust code (or otherwise UTF-8-using code) and text
   node and SpiderMonkey code that uses Latin1.

MozReview-Commit-ID: JaJuExfILM9
2018-08-14 14:43:42 +03:00
Henri Sivonen beda4a1ea9 Bug 634541 - Make the HTML parser remove only one BOM when the input starts with multiple BOMs. r=bzbarsky
MozReview-Commit-ID: 1zoGFxx9MCm

Differential Revision: https://phabricator.services.mozilla.com/D2926

--HG--
extra : moz-landing-system : lando
2018-08-13 08:01:56 +00:00
L. David Baron 1e88f0f003 Bug 1369941: Replace single integers N in fuzzy() and fuzzy-if() with 0-N ranges. r=dholbert
This patch was written entirely by the following script:

  #!/bin/bash

  if [ ! -d "./.hg" ]
  then
    echo "Not in a source tree." 1>&2
    exit 1
  fi

  find . -regex '.*\(ref\|crash\)test.*\.list' | while read FILENAME
  do
    echo "Processing ${FILENAME}."
    # The following has four substitutions:
    # * The first one replaces the *first* argument to fuzzy() when it doesn't
    #   have a - in it, by replacing it with an explicit 0-N range.
    # * The second one does the same for the *second* argument to fuzzy().
    # * The third does the same for the *second* argument to fuzzy-if().
    # * The fourth does the same for the *third* argument to fuzzy-if().
    #
    # Note that this is using perl rather than sed because perl doesn't
    # support non-greedy matching, which is needed for the first argument to
    # fuzzy-if.
    perl -pi -e 's/(fuzzy\()([^ ,()-]*)(,[^ ,()]*\))/${1}0-${2}${3}/g;s/(fuzzy\([^ ,()]*,)([^ ,()-]*)(\))/${1}0-${2}${3}/g;s/(fuzzy-if\([^ ]*?,)([^ ,()-]*)(,[^ ,()]*\))/${1}0-${2}${3}/g;s/(fuzzy-if\([^ ]*?,[^ ,()]*,)([^ ,()-]*)(\))/${1}0-${2}${3}/g' "${FILENAME}"
  done

Differential Revision: https://phabricator.services.mozilla.com/D2974

--HG--
extra : moz-landing-system : lando
2018-08-09 20:10:21 +00:00
Kyle Machulis d920d54421 Bug 1480628 - Remove nsIWebShellServices; r=nika
Summary:
nsIWebShellServices is only implemented by nsDocShell, and only used
in one place in C++. Move definitions to nsIDocShell, and rename
functions to show they are only used as part of Charset changes.

MozReview-Commit-ID: DOSeE3Doc51

Test Plan: Try run

Reviewers: nika

Tags: #secure-revision

Bug #: 1480628

Differential Revision: https://phabricator.services.mozilla.com/D2692
2018-08-07 15:12:55 -07:00
Dave Townsend 7ea0473c02 Bug 1478823: Add a chrome DOM event signalling that the head element's children have been parsed. r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D2612

--HG--
extra : moz-landing-system : lando
2018-08-03 21:16:04 +00:00
Brian Hackett f594284848 Bug 1470795 Part 5 - Update content parse users for API movement, r=froydnj.
--HG--
extra : rebase_source : 856eecd3568adc9873b899a38ad96bbf24ebe955
2018-07-23 21:45:33 +00:00
Brian Hackett e030fb5f6c Bug 1465292 Part 4 - Track parsed content from HTML files, r=hsivonen.
--HG--
extra : rebase_source : cc8c819bc31741e19a29c1d381c783cc6e1ad42e
2018-07-23 21:43:13 +00:00
Nicholas Nethercote fc1f4bb4ae Bug 1476820 - Convert some VarCache prefs in dom/security/ to use StaticPrefs. r=ckerschb
Specifically:
- "security.csp.enable"
- "security.csp.experimentalEnabled"
- "security.csp.enableStrictDynamic"
- "security.csp.reporting.script-sample.max-length"
- "security.csp.enable_violation_events"

MozReview-Commit-ID: G1ie4ut9QaK

--HG--
extra : rebase_source : d6b5a0e79eb7046a13a8b4fe957c82c11831c86c
2018-07-19 10:43:29 +10:00
Andrea Marchesini a053cf1c15 Bug 1476306 - Moving NullPrincipal/ContentPrincipal/SystemPrincipal under mozilla namespace - part 1 - NullPrincipal, r=ckerschb 2018-07-17 21:37:48 +02:00
Andrea Marchesini 14d462eeb3 Bug 1418246 - Return valid columnNumber value in CSP violation events, r=ckerschb 2018-07-05 08:21:04 +02:00
Chris Peterson 2afd829d0f Bug 1469769 - Part 6: Replace non-failing NS_NOTREACHED with MOZ_ASSERT_UNREACHABLE. r=froydnj
This patch is an automatic replacement of s/NS_NOTREACHED/MOZ_ASSERT_UNREACHABLE/. Reindenting long lines and whitespace fixups follow in patch 6b.

MozReview-Commit-ID: 5UQVHElSpCr

--HG--
extra : rebase_source : 4c1b2fc32b269342f07639266b64941e2270e9c4
extra : source : 907543f6eae716f23a6de52b1ffb1c82908d158a
2018-06-17 22:43:11 -07:00
Nicholas Nethercote 60b1f563cb Bug 1447951 - Store nsDynamicAtom's chars after the end of the object. r=froydnj
This reduces memory usage because we only need one allocation instead of two
for the dynamic atom and its chars, and because we don't need to store a
refcount and a size. It precludes sharing of chars between dynamic atoms, but
we weren't benefiting much from that anyway.

This reduces per-process memory usage by up to several hundred KiB on my
Linux64 box.

One consequence of this change is that we need to allocate + copy in
DOMString::SetKnownLiveAtom(), which could make some things slower.

--HG--
extra : rebase_source : ba4065ea31e509dd985c003614199f73def0596c
2018-06-22 09:38:42 +10:00
Andi-Bogdan Postelnicu 0d7d76f23b Bug 1453795 - Parser/HTML - Initialize member fields in classes/ structures. r=hsivonen 2018-06-14 11:46:13 +03:00
Andi-Bogdan Postelnicu 1d049872c5 Bug 1453795 - Parser/HTML Parser - Initialize member fields in classes/ structures. r=mrbkap 2018-06-14 00:08:27 +03:00
Joel Maher 50b91c0a14 Bug 1405428 - skip-if = verify on mochitests which do not pass test-verify. r=gbrown 2018-06-10 05:01:47 -04:00
Joel Maher 5cf551b940 Bug 1392106 - random-if more win7 tests for missing letters. r=RyanVM 2018-06-01 09:29:35 -04:00
Emilio Cobos Álvarez fffb25b74f Bug 1465585: Switch from mozilla::Move to std::move. r=froydnj
This was done automatically replacing:

  s/mozilla::Move/std::move/
  s/ Move(/ std::move(/
  s/(Move(/(std::move(/

Removing the 'using mozilla::Move;' lines.

And then with a few manual fixups, see the bug for the split series..

MozReview-Commit-ID: Jxze3adipUh
2018-06-01 10:45:27 +02:00
Boris Zbarsky 8b9400c98b Bug 1455676 part 19. Remove some remaining nsIDOMNode uses. r=qdot 2018-05-29 22:58:50 -04:00
Joel Maher bea2e0899f Bug 1392106 - random-if many more win7 tests. r=RyanVM 2018-05-29 13:50:33 -04:00
Joel Maher 29d83f200e Bug 1392106 - random-if many more tests on win7. r=RyanVM 2018-05-25 13:03:59 -04:00
Emilio Cobos Álvarez 11794a944d Bug 1461701: Remove nsUpdateType and UPDATE_CONTENT_MODEL. r=smaug
MozReview-Commit-ID: 33iBMZqnkAc
2018-05-15 18:47:16 +02:00
Adrian Wielgosik 074d88de5a Bug 1460940 - Convert nsIPrincipal to use nsIDocument. r=bz
MozReview-Commit-ID: z1TGWtS1KG

--HG--
extra : rebase_source : e5291c40eb017c1e3fd69333ac108dda852fb8cd
2018-05-11 19:46:15 +02:00
Adrian Wielgosik 4fca802957 Bug 1460940 - Convert NS_NewDOMDocument to use nsIDocument. r=bz
MozReview-Commit-ID: GoJ30YZGRhq

--HG--
extra : rebase_source : 0995705c2c31c1a779c22c8336482d4c7e89e319
2018-05-11 19:46:15 +02:00
Andrea Marchesini b5118e1ddf Bug 1302449 - Remove the "referrer" directive in CSP, r=ckerschb 2018-05-09 13:15:08 +02:00
Chris Peterson 71422dcaa9 Bug 1457813 - Part 2: Replace non-asserting NS_PRECONDITIONs with MOZ_ASSERTs. r=froydnj
s/NS_PRECONDITION/MOZ_ASSERT/ and reindent

MozReview-Commit-ID: KuUsnVe2h8L

--HG--
extra : source : c14655ab3df2c9b1465dd8102b9d25683359a37b
2018-04-28 12:50:58 -07:00
Boris Zbarsky 6bf97b61c0 Bug 1455674 part 13. Remove remaining xpidl uses of nsIDOMElement. r=qdot 2018-04-26 23:37:29 -04:00
Emilio Cobos Álvarez a00f507b72 Bug 1456435: Make UpdateStyleSheet less bool-happy. r=heycam
MozReview-Commit-ID: FlTD390lMhg
2018-04-26 16:43:52 +02:00
Adrian Wielgosik b3c501adc4 Bug 1447389 - Remove nsIDOMNodeList. r=bz
MozReview-Commit-ID: 11szZP6dS6V

--HG--
extra : rebase_source : 9acfb352750e53d3b36684fa945a18e817c9b82e
2018-04-25 23:01:30 +02:00
Emilio Cobos Álvarez d8e55e4596 Bug 1454236: Remove nsINode::eDOCUMENT_FRAGMENT. r=bz
MozReview-Commit-ID: D2F3LbQ1pvw
2018-04-20 01:30:12 +02:00