Skip to content

Commit

Permalink
Reland "NEL: Add SQLitePersistentReportingAndNELStore"
Browse files Browse the repository at this point in the history
This is a reland of 8c66199.

Fixes use of uninitialized |num_pending_|.

Original change's description:
> This CL adds SQLitePersistentReportingAndNELStore which persists
> NEL policies to disk in a SQLite database. It will eventually also store
> Reporting clients and reports.
>
> The code is based on that of the SQLitePersistentCookieStore.
>
> It is not hooked up to anything yet (just unittests).
>
> Bug: 895821
> Change-Id: I99ea14ace6f9b7fecd6075b1be98647db80d2bcb
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1504493
> Commit-Queue: Lily Chen <chlily@chromium.org>
> Reviewed-by: Maks Orlovich <morlovich@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#641361}

Bug: 942889, 895821
Change-Id: I679d6713a295715a3a08206f61c91cf58adcd0d7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1528474
Auto-Submit: Lily Chen <chlily@chromium.org>
Reviewed-by: Maks Orlovich <morlovich@chromium.org>
Commit-Queue: Lily Chen <chlily@chromium.org>
Cr-Commit-Position: refs/heads/master@{#641661}
  • Loading branch information
chlily1 authored and Commit Bot committed Mar 18, 2019
1 parent 24f1e17 commit db14198
Show file tree
Hide file tree
Showing 6 changed files with 1,057 additions and 34 deletions.
13 changes: 13 additions & 0 deletions net/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -2363,6 +2363,13 @@ if (!is_proto_quic) {
"//base",
"//sql:sql",
]

if (enable_reporting) {
sources += [
"extras/sqlite/sqlite_persistent_reporting_and_nel_store.cc",
"extras/sqlite/sqlite_persistent_reporting_and_nel_store.h",
]
}
}
}

Expand Down Expand Up @@ -5470,6 +5477,12 @@ test("net_unittests") {
"//base:i18n",
"//sql",
]

if (enable_reporting) {
sources += [
"extras/sqlite/sqlite_persistent_reporting_and_nel_store_unittest.cc",
]
}
} else {
sources -= [
"extras/sqlite/sqlite_channel_id_store_unittest.cc",
Expand Down
Loading

0 comments on commit db14198

Please sign in to comment.