)]}'
{
  "commit": "b22fc9a07d0c8f2cec0425090d3891f7423ad22b",
  "tree": "403bb56995c3aa53d0ac57fcbe783fafa62d6cc4",
  "parents": [
    "55835a2c6af83c4d78394c50670e97606b8b7eef"
  ],
  "author": {
    "name": "Lei Zhang",
    "email": "thestig@chromium.org",
    "time": "Sat Sep 16 01:24:58 2023 +0000"
  },
  "committer": {
    "name": "Pdfium LUCI CQ",
    "email": "pdfium-scoped@luci-project-accounts.iam.gserviceaccount.com",
    "time": "Sat Sep 16 01:24:58 2023 +0000"
  },
  "message": "Don\u0027t implement CPDF_DIB::GetBuffer() (try 2)\n\nThe first try [1] to just return an empty span in CPDF_DIB::GetBuffer()\ndid not work. This CL goes further and deletes CFX_DIBBase::GetBuffer()\naltogether. Instead, only implement a non-virtual\nCFX_DIBBitmap::GetBuffer(). To make this work, get rid of all\nCFX_DIBBase::GetBuffer() callers:\n\n- Switch to calling CFX_DIBBitmap::GetBuffer() when it easy to do so.\n- Make CFX_DIBBase::RealizeIfNeeded() virtual, and change the default\n  implementation to just call Realize().\n- Make RealizeIfNeeded() available for Skia-builds and use it in\n  CreateSkiaImageFromDib().\n- Change CreateSkiaImageFromTransformedDib() to only use scanlines.\n\nFix other issues to make sure everything works:\n\n- Avoid calling RealizeIfNeeded() on `CPDF_DIB::m_pCachedBitmap`, as\n  that gives the wrong answer, just like CPDF_DIB::GetBuffer().\n- Make sure CreateSkiaImageFromDib() does not fail and leak memory.\n- Give up on avoiding the CachedImage::SkipToScanline() call.\n- Add a test case for a related bug.\n\n[1] https://pdfium-review.googlesource.com/108850\n\nBug: chromium:1478366,pdfium:2050,pdfium:2051\nChange-Id: Ia20d4d257d441dd971ee0a912733f48f29dafad1\nReviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/111434\nReviewed-by: Nigi \u003cnigi@chromium.org\u003e\nCommit-Queue: Lei Zhang \u003cthestig@chromium.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "c478d37dcbf579b3a3e80d1b93b89e5aa064bf0c",
      "old_mode": 33188,
      "old_path": "core/fpdfapi/page/cpdf_dib.cpp",
      "new_id": "657cf16b26b304a5102fd849ec0112fe01f0b1c2",
      "new_mode": 33188,
      "new_path": "core/fpdfapi/page/cpdf_dib.cpp"
    },
    {
      "type": "modify",
      "old_id": "5206bf5532002ea8fae0c7da09b90c09d104c03c",
      "old_mode": 33188,
      "old_path": "core/fpdfapi/page/cpdf_dib.h",
      "new_id": "1ef656a4491527263f58dbbfc9ce297da926fc38",
      "new_mode": 33188,
      "new_path": "core/fpdfapi/page/cpdf_dib.h"
    },
    {
      "type": "modify",
      "old_id": "b36f089d22cfaeb1b1217844d6eb69badeae9811",
      "old_mode": 33188,
      "old_path": "core/fpdfapi/page/cpdf_pageimagecache.cpp",
      "new_id": "30d6aa151df2d6498663224bd137595467d76d4c",
      "new_mode": 33188,
      "new_path": "core/fpdfapi/page/cpdf_pageimagecache.cpp"
    },
    {
      "type": "modify",
      "old_id": "2a80f892bf3da67c751525dadc81d35f6281eef1",
      "old_mode": 33188,
      "old_path": "core/fxge/dib/cfx_dibbase.cpp",
      "new_id": "bf823dcb7490a3398daa265366d720d5c475dac1",
      "new_mode": 33188,
      "new_path": "core/fxge/dib/cfx_dibbase.cpp"
    },
    {
      "type": "modify",
      "old_id": "63278887e6915124eddada699569d32c6ebfc6eb",
      "old_mode": 33188,
      "old_path": "core/fxge/dib/cfx_dibbase.h",
      "new_id": "98febad55eea321857512c3d5193b94664405a80",
      "new_mode": 33188,
      "new_path": "core/fxge/dib/cfx_dibbase.h"
    },
    {
      "type": "modify",
      "old_id": "6df1eee1e98918cd6840070b5a4d6f9bc46f677e",
      "old_mode": 33188,
      "old_path": "core/fxge/dib/cfx_dibitmap.cpp",
      "new_id": "cf349c0e714cd43e80e1dd8265ba69833324b0ef",
      "new_mode": 33188,
      "new_path": "core/fxge/dib/cfx_dibitmap.cpp"
    },
    {
      "type": "modify",
      "old_id": "34f58872286f3a21b81143dc59df8dff98bf70bb",
      "old_mode": 33188,
      "old_path": "core/fxge/dib/cfx_dibitmap.h",
      "new_id": "e59644d1332c06beeacbf0ceedbd4ced22e8413f",
      "new_mode": 33188,
      "new_path": "core/fxge/dib/cfx_dibitmap.h"
    },
    {
      "type": "modify",
      "old_id": "417aa93b627a88045a733b2faddcee7939d58c82",
      "old_mode": 33188,
      "old_path": "core/fxge/skia/cfx_dibbase_skia.cpp",
      "new_id": "8606e336bb94046a977fbbf4345c2e0fb695fd90",
      "new_mode": 33188,
      "new_path": "core/fxge/skia/cfx_dibbase_skia.cpp"
    },
    {
      "type": "modify",
      "old_id": "e4c2b15d6a3acf830a6732ed49543d4d758fb2c9",
      "old_mode": 33188,
      "old_path": "core/fxge/win32/cgdi_device_driver.cpp",
      "new_id": "e6e2c211777d404dccd5dbaec641ef8adbb24691",
      "new_mode": 33188,
      "new_path": "core/fxge/win32/cgdi_device_driver.cpp"
    },
    {
      "type": "modify",
      "old_id": "f6a9181f842d83b2f853d5e8bbdbe756b9e8e02f",
      "old_mode": 33188,
      "old_path": "core/fxge/win32/cgdi_plus_ext.cpp",
      "new_id": "0cd0a37a6a1412825523782abec864946a7c0fca",
      "new_mode": 33188,
      "new_path": "core/fxge/win32/cgdi_plus_ext.cpp"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "5749b52ffa15190a99ff85780df9571de762d8b0",
      "new_mode": 33188,
      "new_path": "testing/resources/pixel/bug_1478366.in"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "23e62966e8494a73d32591b34659ebd767340e2b",
      "new_mode": 33188,
      "new_path": "testing/resources/pixel/bug_1478366_expected.pdf.0.png"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "baf8b4b79b1b6984a3831b186966ab2db2323140",
      "new_mode": 33188,
      "new_path": "testing/resources/pixel/bug_1478366_expected_skia.pdf.0.png"
    }
  ]
}
