1. 07 Feb, 2018 31 commits
  2. 06 Feb, 2018 9 commits
    • Victor Costan's avatar
      sqlite: Prefix SQLite API methods with chrome_. · 3d8ec487
      Victor Costan authored
      In component builds, SQLite's API methods are exported from the
      chromium_sqlite component, which means they are visible to the dynamic
      library loader. This opens up the following possibilities:
      
      1) A system library calls into our SQLite instead of calling into the
         system's SQLite library which it was built against. The patches in
         our SQLite version lead to different behavior from the system's
         SQLite, which can cause subtle failures. This happens if the dynamic
         library loader resolves the system library's symbol imports with our
         SQLite's exported symbols.
      2) A system library loads the system SQLite, and we end up calling into
         it, instead of calling into our version of SQLite. This happens if
         the dynamic library loader resolves our symbol imports with the
         system's SQLite library.
      
      Both possibilities above lead to the possibility that the component
      build will behave differently from the release build, in subtle and
      potentially non-deterministic ways. This is not a purely academic
      concern. https://crbug.com/807487 happened because we use NSS on Linux,
      and NSS invokes SQLite via a complex plugin system. On non-component builds,
      NSS (a system library) loads and uses the system version of SQLite. On
      component builds, NSS ends up using our SQLite.
      
      This CL fixes the problem by adding a chrome_ prefix to all the symbols
      exported from SQLite3. In C++ libraries, namespaces can make prefixing
      easy. Unfortunately, SQLite is a C library, so the prefixing is fairly
      heavy-handed. A high-level overview of the approach follows:
      
      * An extract_sqlite_api Python script reads SQLite's header, extracts
        the names of all exported symbols, and writes a header file consisting
        of renaming preprocessor macros, e.g.
            #define sqlite3_init chrome_sqlite3_init
        David Benjamin <davidben@chromium.org> designed the approach and wrote
        the original version of the script.
      * The script that we use to generate SQLite's amalgamation now also
        invokes the extract_sqlite_api script described above, and saves the
        output to amalgamation/rename_exports.h.
      * The SQLite component exposes an sqlite3.h header that must be used by
        all SQLite3 users in Chromium. This header now #includes
        rename_exports.h (containing the renaming preprocessor macros) before
        #including amalgamation/sqlite3.h.
      * sqlite3.c (the main output of the amalgamation process) does not
        #include "sqlite3.h". However, in order to facilitate autoconf builds,
        it does #include a "config.h", if a certain preprocessor define
        exists. We abuse that define to have sqlite.c always load config.h,
        and have config.h load our rename_exports.h.
      
      This CL also adds a PRESUBMIT.py that runs unit tests for the
      extract_sqlite_api Python script, which ensures that the script will not
      break accidentally. Both the unit tests and the PRESUBIMT script are
      inspired from //tools/vim.
      
      Bug: 807093, 807487
      Change-Id: If3868ba119ffd4ccbb06d1a6fcd4cc2ecd9ef2ae
      Reviewed-on: https://chromium-review.googlesource.com/898549Reviewed-by: default avatarChris Mumford <cmumford@chromium.org>
      Commit-Queue: Victor Costan <pwnall@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#534843}
      3d8ec487
    • Alexander Timin's avatar
      [scheduler] Fix crash when clearing TaskQueue task handlers. · 5157f928
      Alexander Timin authored
      Move deinitialisation of TaskQueue's OnTaskStartedHandler and
      OnTaskCompletedHandler to main thread and avoid race condition.
      
      R=skyostil@chromium.org
      BUG=809424
      
      Change-Id: I1c67ceead20e9b8463de054ce3040314d4fee002
      Reviewed-on: https://chromium-review.googlesource.com/904605Reviewed-by: default avatarSami Kyöstilä <skyostil@chromium.org>
      Commit-Queue: Alexander Timin <altimin@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#534842}
      5157f928
    • Xiyuan Xia's avatar
      cros: Remove debugging code for user profile loading · 15dcddfb
      Xiyuan Xia authored
      Debugging code to track app terminiating while loading
      user profile is added in M63. Two milestones has passed
      and the problem no longer happens. Hence removing it.
      
      Bug: 717585
      Change-Id: I7df6ea9c4ab9809e4a86b36136aa69e1b03a5ead
      Reviewed-on: https://chromium-review.googlesource.com/905063Reviewed-by: default avatarAchuith Bhandarkar <achuith@chromium.org>
      Commit-Queue: Xiyuan Xia <xiyuan@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#534841}
      15dcddfb
    • Elad Alon's avatar
      RenderProcessHost exiting is an implicit PeerConnection removal · 022ed8ae
      Elad Alon authored
      When a RenderProcessHost exits clearly or crashes, all of its
      PeerConnections should be considered as removed.
      
      Bug: 775415, 805398, 808402
      Change-Id: I223e6e867758ef05d896608fbdcc3bc824238dd8
      Reviewed-on: https://chromium-review.googlesource.com/899348
      Commit-Queue: Elad Alon <eladalon@chromium.org>
      Reviewed-by: default avatarGuido Urdaneta <guidou@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#534840}
      022ed8ae
    • Matthew Jones's avatar
      [Modern] Improve tab switcher theme color animations · 4982f7ba
      Matthew Jones authored
      This change removes the use of transparency on the location bar when
      modern is enabled. This simplifies the logic required to run animations
      and fixes a flickering issue when entering and exiting the tab switcher.
      
      This change also changes the background color of the asset to white.
      This allows it to be easily tinted which will also be required for the
      composited version.
      
      BUG=803098,803091
      
      Change-Id: Ia56660da21f615840f6ea2902a3252b8809d337f
      Reviewed-on: https://chromium-review.googlesource.com/899772
      Commit-Queue: Matthew Jones <mdjones@chromium.org>
      Reviewed-by: default avatarTed Choc <tedchoc@chromium.org>
      Reviewed-by: default avatarTheresa <twellington@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#534839}
      4982f7ba
    • yiyix's avatar
      Using CompositorFrameSinkSupport to handle the copy request · e544a1ed
      yiyix authored
      In the current implementation, the copy request is handled by
      DelegatedFrameHost::RequestCopyOfOutput, which add copy request to
      the compositor frame of the browser. After this patch, the copy
      request will be handled by the
      CompositorFrameSinkSupport:RequestCopyOfSurface which adds the
      copy request to the surface where the copy request needs to be make.
      
      TEST: exiting test cases on copy requests should cover all the usage
      
      Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel
      Change-Id: I5c0b4572a7b8ed5fce0f5ee10f5d4dd982912e0a
      Reviewed-on: https://chromium-review.googlesource.com/881548Reviewed-by: default avatarYuri Wiitala <miu@chromium.org>
      Reviewed-by: default avatarccameron <ccameron@chromium.org>
      Commit-Queue: Yi Xu <yiyix@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#534838}
      e544a1ed
    • Ted Choc's avatar
      Add clarifying comment in UrlBar.java for copy/cut handling. · 45236331
      Ted Choc authored
      BUG=
      
      Change-Id: I5372417f961594c3907ebde5f38a1512c83f189d
      Reviewed-on: https://chromium-review.googlesource.com/903182Reviewed-by: default avatarMaria Khomenko <mariakhomenko@chromium.org>
      Commit-Queue: Maria Khomenko <mariakhomenko@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#534837}
      45236331
    • Jacob Dufault's avatar
      cros: Move keep_alive and drag'n'drop to LoginDisplayHostCommon. · d742024d
      Jacob Dufault authored
      - keep_alive ensures we do not exit/shutdown.
      - drag'n'drop disables drag and drop.
      
      Bug: 784495
      Change-Id: I65525cf5065db48bc14db93af3f3b6e86bc715c7
      Reviewed-on: https://chromium-review.googlesource.com/871835
      Commit-Queue: Jacob Dufault <jdufault@chromium.org>
      Reviewed-by: default avatarAchuith Bhandarkar <achuith@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#534836}
      d742024d
    • Jinsuk Kim's avatar
      Fix crash in ContentViewCore.onRotationChanged · 8c3fa7b9
      Jinsuk Kim authored
      Reporte crash can happen if |ContentViewCore.onRotationChanged| is called
      after CVC is destroyed, therefore mWebContents is set to null. Added
      null check against the variable to prevent crash.
      
      Bug: 808971
      Change-Id: I7719d2d0c26b36b94eeff406d655512111e58c2d
      Reviewed-on: https://chromium-review.googlesource.com/903342Reviewed-by: default avatarTed Choc <tedchoc@chromium.org>
      Commit-Queue: Jinsuk Kim <jinsukkim@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#534835}
      8c3fa7b9