0
Commit Graph

22 Commits

Author SHA1 Message Date
Tom Sepez
8726d30ed0 Suppress unsafe_libc_call warning for initial identified files.
See docs/unsafe_buffers.md for details. Enforcement is not yet
enabled, but this set of files are not in compliance with the
new warnings.

Bug: 390223051
Change-Id: I4e24c2141b9399f572678302c833947494098b29
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6187925
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Owners-Override: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1412673}
2025-01-28 18:11:08 -08:00
Taiyo Mizuhashi
5ef7635ae6 [CodeHealth] Remove RAW_PTR_EXCLUSION from ShapeDetectionBrowserTest
Fixed: 346693701
Change-Id: I5c70d30568c897e567e6811726b0b9c849608587
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5691566
Reviewed-by: Jack Hsieh <chengweih@chromium.org>
Commit-Queue: Taiyo Mizuhashi <taiyo@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1326328}
2024-07-11 19:56:37 +00:00
Bartek Nowierski
26a2cce4b8 [BRP] Remove #constexpr-* exclusions (and modernize comments)
No rewrites were necessary. In vast majority of cases there was another exclusion reason barring from making a rewrite. In the 2 cases where no other reason was listed, turns out the embedding struct is STACK_ALLOCATED, so we don't rewrite such pointers.

Bug: 346694917
Change-Id: I6b8002e424dc4d6b3952567382eb81b926e55244
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5632968
Reviewed-by: Keishi Hattori <keishi@chromium.org>
Commit-Queue: Keishi Hattori <keishi@chromium.org>
Auto-Submit: Bartek Nowierski <bartekn@chromium.org>
Owners-Override: Keishi Hattori <keishi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1318385}
2024-06-23 21:34:06 +00:00
Alison Gale
53c77f6b62 Migrate TODOs referencing old crbug IDs to the new issue tracker IDs
The canonical bug format is TODO(crbug.com/<id>). TODOs of the
following forms will all be migrated to the new format:

- TODO(crbug.com/<old id>)
- TODO(https://crbug.com/<old id>)
- TODO(crbug/<old id>)
- TODO(crbug/monorail/<old id>)
- TODO(<old id>)
- TODO(issues.chromium.org/<old id>)
- TODO(https://issues.chromium.org/<old id>)
- TODO(https://issues.chromium.org/u/1/issues/<old id>)
- TODO(bugs.chromium.org/<old id>)

Bug id mapping is sourced from go/chrome-on-buganizer-prod-issues.
See go/crbug-todo-migration for details.

#crbug-todo-migration

Bug: b/321899722
Change-Id: Iabdfea2fd5393d6bbc54390ca0c995eb2c55bbaa
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5469882
Reviewed-by: Darryl James <dljames@chromium.org>
Owners-Override: Alison Gale <agale@chromium.org>
Commit-Queue: Alison Gale <agale@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1290673}
2024-04-22 15:16:27 +00:00
Jeff Yoon
d1328c4408 [buganizer] Migrate DIR_METADATA in content/browser/
Migrate all metadata files for content/browser.

Verify components with http://b/components/{id} or at
go/chrome-on-buganizer-prod-components.

Bug: chromium:1518875
Change-Id: I555b9fe40952a5707e167b3dcbaf2858bbdf1f34
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5284095
Reviewed-by: Avi Drissman <avi@chromium.org>
Commit-Queue: Avi Drissman <avi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1258966}
2024-02-11 19:24:26 +00:00
Ali Hijazi
6d1cf699ab Add RAW_PTR_EXCLUSION to fields
Add RAW_PTR_EXCLUSION to fields that the rewriter could not
automatically rewrite. This change was generated by processing the
output of the rewriter.

Bug: 1446146
Change-Id: I43d3f2793fe1106cdf4e5d9ca7ceace476afeb92
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4556208
Reviewed-by: Arthur Sonzogni <arthursonzogni@chromium.org>
Commit-Queue: Ali Hijazi <ahijazi@chromium.org>
Reviewed-by: Bartek Nowierski <bartekn@chromium.org>
Owners-Override: Arthur Sonzogni <arthursonzogni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1148429}
2023-05-24 09:39:28 +00:00
Chris Fredrickson
b854bbf9be Remove some usages of EXECUTE_SCRIPT_USE_MANUAL_REPLY under content/
Removing reliance on EXECUTE_SCRIPT_USE_MANUAL_REPLY forces the
JavaScript to be written in terms of promises, which makes the code
less bug-prone since double-sends are systematically prevented (see
https://crrev.com/c/4318742 for an example bug that would have been
prevented by this).

There are still more usages, especially under content/browser/webrtc,
but those removals are not as mechanical and will be attempted in
followups.

Bug: 1423407, 1422660
Change-Id: Ib8f153da50f0bd3e2d09e00615973264dc3214d4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4332196
Reviewed-by: Dale Curtis <dalecurtis@chromium.org>
Auto-Submit: Chris Fredrickson <cfredric@chromium.org>
Commit-Queue: Chris Fredrickson <cfredric@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1122508}
2023-03-27 17:27:44 +00:00
Avi Drissman
4e1b7bc33d Update copyright headers in content/
The methodology used to generate this CL is documented in
https://crbug.com/1098010#c34.

No-Try: true
No-Presubmit: true
Bug: 1098010
Change-Id: I8c0f009d16350271f07d8e5e561085822cc9dd27
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3895935
Owners-Override: Avi Drissman <avi@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Mark Mentovai <mark@chromium.org>
Auto-Submit: Avi Drissman <avi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1047456}
2022-09-15 14:03:50 +00:00
Xiaohan Wang
1ecfd006fd content: Use BUILDFLAG for OS checking
Use BUILDFLAG(IS_XXX) instead of defined(OS_XXX).

Generated by `os_buildflag_migration.py` (https://crrev.com/c/3311983).

R=thakis@chromium.org

Bug: 1234043
Test: No functionality change
Change-Id: Ia0eae6f9396065e190929d42600012c9324c07e9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3399774
Commit-Queue: Xiaohan Wang <xhwang@chromium.org>
Owners-Override: Xiaohan Wang <xhwang@chromium.org>
Auto-Submit: Xiaohan Wang <xhwang@chromium.org>
Reviewed-by: Nico Weber <thakis@chromium.org>
Commit-Queue: Nico Weber <thakis@chromium.org>
Owners-Override: Nico Weber <thakis@chromium.org>
Cr-Commit-Position: refs/heads/main@{#961157}
2022-01-19 22:33:10 +00:00
Avi Drissman
c91bd8ea79 Migrate to ExecJs/EvalJs in content/
Bug: 1157718
Change-Id: Ibb5bdb3f994630cc2b84f4e60adaf307fe646cb3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2826401
Auto-Submit: Avi Drissman <avi@chromium.org>
Commit-Queue: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Cr-Commit-Position: refs/heads/master@{#874039}
2021-04-19 23:58:44 +00:00
Josip Sokcevic
0186d8a4e6 [3/N] Add DIR_METADATA files to directories under //content
Generate DIR_METADATA files and remove metadata from OWNERS
files for directories under //content.

R=boliu@chromium.org

Bug: 1113033
Change-Id: Iab77bab240ce5482ad7ae97ae5c37555f15f0241
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2543250
Reviewed-by: Bo <boliu@chromium.org>
Commit-Queue: Bo <boliu@chromium.org>
Auto-Submit: Josip Sokcevic <sokcevic@google.com>
Cr-Commit-Position: refs/heads/master@{#828340}
2020-11-17 20:20:14 +00:00
Avi Drissman
7c57be77a7 Migrate to OS_MAC and OS_APPLE in content
Because content is not used by iOS, this migrates
 defined(OS_MACOSX) -> defined(OS_MAC)

Bug: 1105907
Change-Id: Ibf85273fea9c5566594ca00f2589b890515be6c7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2321210
Commit-Queue: Avi Drissman <avi@chromium.org>
Reviewed-by: Nasko Oskov <nasko@chromium.org>
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Cr-Commit-Position: refs/heads/master@{#792842}
2020-07-29 20:09:46 +00:00
Peter Kasting
919ce657e4 Add missing #includes of browser_test.h.
This is a step towards doing full IWYU of browser_test.h, which will
have other benefits.

Completely mechanical and already R+ed as part of r765923.

Tbr: sky
Bug: none
Change-Id: Icb7ab728098a6cf29c0920da4b524e96a7c024c2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2186411
Commit-Queue: Peter Kasting <pkasting@chromium.org>
Reviewed-by: Peter Kasting <pkasting@chromium.org>
Cr-Commit-Position: refs/heads/master@{#766361}
2020-05-07 10:22:36 +00:00
Balazs Engedy
683d2c7a8f Revert "IWYU for browser_test.h."
This reverts commit 66a53c909a.

Reason for revert: Breaks compile on official branded builders.

Original change's description:
> IWYU for browser_test.h.
> 
> Include this directly in relevant test files.  This lets us convert the
> HAS_OUT_OF_PROC_TEST_RUNNER checks in this file and
> view_event_test_base.h into #errors, and force people to not even
> include this file in files that can't use it.
> 
> Bug: none
> Tbr: sky
> Change-Id: I86626099eb047eb53e8b3611de38ba6bebc01a0b
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2136117
> Commit-Queue: Peter Kasting <pkasting@chromium.org>
> Reviewed-by: Scott Violet <sky@chromium.org>
> Reviewed-by: Lei Zhang <thestig@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#765923}

TBR=sky@chromium.org,pkasting@chromium.org,thestig@chromium.org

Change-Id: I4583916602404c310a93f571dd2c78645c6bd567
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: none
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2184132
Reviewed-by: Balazs Engedy <engedy@chromium.org>
Commit-Queue: Balazs Engedy <engedy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#765931}
2020-05-06 10:36:40 +00:00
Peter Kasting
66a53c909a IWYU for browser_test.h.
Include this directly in relevant test files.  This lets us convert the
HAS_OUT_OF_PROC_TEST_RUNNER checks in this file and
view_event_test_base.h into #errors, and force people to not even
include this file in files that can't use it.

Bug: none
Tbr: sky
Change-Id: I86626099eb047eb53e8b3611de38ba6bebc01a0b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2136117
Commit-Queue: Peter Kasting <pkasting@chromium.org>
Reviewed-by: Scott Violet <sky@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Cr-Commit-Position: refs/heads/master@{#765923}
2020-05-06 09:38:56 +00:00
Reilly Grant
57ae4c5d33 Create separate Blink feature flags for Shape Detection APIs
The BarcodeDetector, FaceDetector and TextDetector APIs will be released
individually. This change creates separate runtime enabled feature flags
for each to allow this staggered release.

BarcodeDetector is marked stable for launch.

Intent to Ship: https://groups.google.com/a/chromium.org/d/msg/blink-dev/j-PLtssE5fo/budv_U6fCwAJ

Bug: 659138
Change-Id: I880ac0d4a619e907b7e310b514f082b470bfad14
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1717915
Commit-Queue: Reilly Grant <reillyg@chromium.org>
Reviewed-by: Yoav Weiss <yoavweiss@chromium.org>
Auto-Submit: Reilly Grant <reillyg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#741673}
2020-02-15 00:40:35 +00:00
Ilia Samsonov
1ad9ea3df2 Add prefix to empty param tests.
googletest will no longer support empty prefix
for parameterized INSTANTIATE_TEST_SUITE_P.
Adding "All" prefix to existing empty prefix test suites.

This CL was uploaded by git cl split.

R=mcasas@chromium.org

Bug: 1023677
Change-Id: Ib685f8d5159bdbbeed15bf098e07d3843acd45d0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1926991
Auto-Submit: Ilia Samsonov <isamsonov@google.com>
Reviewed-by: Miguel Casas <mcasas@chromium.org>
Commit-Queue: Miguel Casas <mcasas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#718637}
2019-11-25 14:48:00 +00:00
Alex Moshchuk
aeb20fe347 Fix remaining NavigateToURL expectations in content_browsertests.
This is hopefully the last step before finally adding
WARN_UNUSED_RESULT to NavigateToURL().

Apart from adding straightforward expectations for regular and redirect
cases, this fixes a couple more bugs:

- AppendingFrameInWebUIDoesNotCrash was broken on Android, because it
  used chrome://tracing, which doesn't exist on Android.

- A couple of tests in WebContentsImplBrowserTest (e.g.,
  ChangeDisplayMode) were navigating to about://blank (instead of
  about:blank), which results in an error rather than a blank page.

Bug: 425335
Change-Id: Id80040de9c3383c517f2df95b819f314e6b29f30
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1819852
Reviewed-by: Łukasz Anforowicz <lukasza@chromium.org>
Commit-Queue: Alex Moshchuk <alexmos@chromium.org>
Cr-Commit-Position: refs/heads/master@{#699854}
2019-09-25 17:40:01 +00:00
Reilly Grant
9dcebf1eea Add OWNERS file for //content/browser/shape_detection
Also unifies the OWNERS files for //services/shape_detection and
//third_party/blink/renderer/modules/shapedetection.

Change-Id: I8660d84eafbd50dfdec83a2cf81808ec76ae4699
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1718354
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Commit-Queue: Reilly Grant <reillyg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#680954}
2019-07-25 20:05:14 +00:00
Victor Costan
aa7b61fdc4 test: Replace _TEST_CASE_ with _TEST_SUITE_ in /content.
Googletest is (at last) converging with industry-standard terminology
[1]. We previously called test suites "test cases", which was rather
confusing for folks coming from any other testing framework.

Chrome now has a googletest version that supports _TEST_SUITE_ macros
instead of _TEST_CASE_, so this CL cleans up some of the outdated usage.

[1] https://github.com/google/googletest/blob/master/googletest/docs/primer.md#beware-of-the-nomenclature

Bug: 925652
Change-Id: Id6f209a71ef005b068b2dbe4308291af444544ec
Reviewed-on: https://chromium-review.googlesource.com/c/1469525
Auto-Submit: Victor Costan <pwnall@chromium.org>
Commit-Queue: Kinuko Yasuda <kinuko@chromium.org>
Reviewed-by: Kinuko Yasuda <kinuko@chromium.org>
Cr-Commit-Position: refs/heads/master@{#631597}
2019-02-13 07:57:57 +00:00
Chris Nardi
3e51c4beca Remove GeometryInterfaces runtime flag
GeometryInterfaces was promoted to stable by https://crrev.com/481096,
which landed in M61. Remove the flag as it is no longer needed.

Bug: 402536
Change-Id: I56e739958ca13c1185889070b99e32efa501c46b
Reviewed-on: https://chromium-review.googlesource.com/1043092
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Reviewed-by: Avi Drissman <avi@chromium.org>
Commit-Queue: Chris Nardi <cnardi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#555947}
2018-05-04 01:15:07 +00:00
mcasas
04e8ca7031 Shape detection: moar content_browsertests (face, qr/barcode)
In the spirit of "if it can be tested, it ought to be tested", this
CL cleans up and expands the a few tests related to Shape Detection.

- the current content_browsertest, which on ToT is extended to
work on Mac and cleaned up (generalized and parameterized, variable
names clarified).

- the test face is changed to a smaller, public domain one of size
6182B (~1.4K smaller).

- Also corrected names: s/shapedetection/shape_detection/

- QR/barcode and text detection in Android is based on coreGMS,
so need to be tested under chrome/. A new ShapeDetectionTest.java
is added for that.  To use coreGMS, we have to guarantee that
StrictMode.allowThreadDiskWrites().

BUG=665150, 676124

Review-Url: https://codereview.chromium.org/2711893003
Cr-Commit-Position: refs/heads/master@{#453818}
2017-03-01 03:19:19 +00:00