From ddc23493d4fbb94d5d48af88e08b090dd25ba432 Mon Sep 17 00:00:00 2001 From: Lovell Fuller Date: Fri, 25 May 2018 19:53:23 +0100 Subject: [PATCH] Add warning about possible concurrent tile race #1151 --- docs/api-output.md | 2 ++ lib/output.js | 2 ++ 2 files changed, 4 insertions(+) diff --git a/docs/api-output.md b/docs/api-output.md index 0f97e86d..e54c943c 100644 --- a/docs/api-output.md +++ b/docs/api-output.md @@ -279,6 +279,8 @@ Use tile-based deep zoom (image pyramid) output. Set the format and options for tile images via the `toFormat`, `jpeg`, `png` or `webp` functions. Use a `.zip` or `.szi` file extension with `toFile` to write to a compressed archive file format. +Warning: multiple sharp instances concurrently producing tile output can expose a possible race condition in some versions of libgsf. + **Parameters** - `tile` **[Object][15]?** diff --git a/lib/output.js b/lib/output.js index 0bb880d4..db2df2b2 100644 --- a/lib/output.js +++ b/lib/output.js @@ -390,6 +390,8 @@ function toFormat (format, options) { * Set the format and options for tile images via the `toFormat`, `jpeg`, `png` or `webp` functions. * Use a `.zip` or `.szi` file extension with `toFile` to write to a compressed archive file format. * + * Warning: multiple sharp instances concurrently producing tile output can expose a possible race condition in some versions of libgsf. + * * @example * sharp('input.tiff') * .png()