)]}'
{
  "commit": "ed2828ff7f52659b371c37b96c137611614e6fde",
  "tree": "c09386d20f50702a2c7d537853cbf5ddb6bce253",
  "parents": [
    "6a1250879d7225cc0cc82a19f53571a53b791bc4"
  ],
  "author": {
    "name": "Mark Mentovai",
    "email": "mark@chromium.org",
    "time": "Mon Nov 07 20:04:19 2022 +0000"
  },
  "committer": {
    "name": "Pdfium LUCI CQ",
    "email": "pdfium-scoped@luci-project-accounts.iam.gserviceaccount.com",
    "time": "Mon Nov 07 20:04:19 2022 +0000"
  },
  "message": "Replace sprintf calls with snprintf in third_party\n\nThis makes it possible to build PDFium without warnings using the macOS\n13 SDK. Calls to sprintf are replaced with snprintf, passing appropriate\nbuffer sizes.\n\nIt doesn’t appear that any of the changed uses of sprintf were actually\nunsafe, so no behavior change is expected aside from SDK compatibility.\n\nThe macOS 13 SDK deprecates sprintf as it’s difficult to use safely. The\ndeprecation warning message is visible when building C++, but it is not\nnormally visible when building plain C code due to a quirk in how\nsprintf is declared in the SDK. However, the deprecation message is\nvisible when building plain C under Address Sanitizer\n(-fsanitize\u003daddress). This discrepancy was discovered at\nhttps://crbug.com/1381706 and reported to Apple with a copy at\nhttps://openradar.appspot.com/FB11761475.\n\nThe macOS 13 SDK is packaged in Xcode 14.1, released on 2022-11-01. This\nalso affects the iOS 16 SDK and other 2022-era Apple OS SDKs packaged in\nXcode 14.0, released on 2022-09-12.\n\nThis change affects libopenjpeg and libtiff. The patches here were\nsubmitted upstream at https://github.com/uclouvain/openjpeg/pull/1450\nand https://gitlab.com/libtiff/libtiff/-/merge_requests/408.\n\nBug: chromium:1381706\nChange-Id: I92ff8f897fe63b3dee14301cd15c791e0d4fb8cf\nReviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/100790\nCommit-Queue: Lei Zhang \u003cthestig@chromium.org\u003e\nReviewed-by: Lei Zhang \u003cthestig@chromium.org\u003e\n",
  "tree_diff": [
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "01ef487a5fc258275ffbc73c340162846884aec4",
      "new_mode": 33188,
      "new_path": "third_party/libopenjpeg/0045-openjp2-j2k-replace-sprintf-calls-with-snprintf.patch"
    },
    {
      "type": "modify",
      "old_id": "49b39be83c2ec4956637092cdbf490a8387ba378",
      "old_mode": 33188,
      "old_path": "third_party/libopenjpeg/README.pdfium",
      "new_id": "9498b86f228a0b78c9c12ed54a13e5c765c4ddcf",
      "new_mode": 33188,
      "new_path": "third_party/libopenjpeg/README.pdfium"
    },
    {
      "type": "modify",
      "old_id": "fce12e442b4640e30e13038ac55fb9c059da2df6",
      "old_mode": 33188,
      "old_path": "third_party/libopenjpeg/j2k.c",
      "new_id": "9b06e7ec89f9eb0c3fdd6b0d1683f4691cafcef2",
      "new_mode": 33188,
      "new_path": "third_party/libopenjpeg/j2k.c"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "ae69dff2f60270a22f30b5c1024edc3a1de92b22",
      "new_mode": 33188,
      "new_path": "third_party/libtiff/0036-Replace-sprintf-calls-with-snprintf.patch"
    },
    {
      "type": "modify",
      "old_id": "8a6bd5ba10da4416f8cf75d0e0006127de7e0871",
      "old_mode": 33188,
      "old_path": "third_party/libtiff/README.pdfium",
      "new_id": "fe3f74615217c69eb39c2c77eb30ef247342c550",
      "new_mode": 33188,
      "new_path": "third_party/libtiff/README.pdfium"
    },
    {
      "type": "modify",
      "old_id": "f909b20c13257aaee0f0c2cbf11e0480d233d52d",
      "old_mode": 33188,
      "old_path": "third_party/libtiff/tif_codec.c",
      "new_id": "d01259ca78c8a1170e6930c48bda8b4c9d6c6b72",
      "new_mode": 33188,
      "new_path": "third_party/libtiff/tif_codec.c"
    },
    {
      "type": "modify",
      "old_id": "2e88c9bdc4b45507d446406cc3c79ea92c8ab438",
      "old_mode": 33188,
      "old_path": "third_party/libtiff/tif_getimage.c",
      "new_id": "5906d6d06d81fb4e22695b4f5344bc94fe1ab3bc",
      "new_mode": 33188,
      "new_path": "third_party/libtiff/tif_getimage.c"
    }
  ]
}
