diff options
author | Akira Kakuto <kakuto@fuk.kindai.ac.jp> | 2015-10-07 04:20:07 +0000 |
---|---|---|
committer | Akira Kakuto <kakuto@fuk.kindai.ac.jp> | 2015-10-07 04:20:07 +0000 |
commit | e09dd5638b67d66f92d29b9a4a2d33d5c84ac50d (patch) | |
tree | 1327c3ab14e04b38c7f692e3b920a08a1ecc10fd /Build/source/texk | |
parent | a021762e6ccc1101fefbac38abb168b69a11f0ca (diff) |
luatexdir/image/epdf.h: Support Visual Studio 2010 for log().
git-svn-id: svn://tug.org/texlive/trunk@38576 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk')
-rw-r--r-- | Build/source/texk/web2c/luatexdir/ChangeLog | 1 | ||||
-rw-r--r-- | Build/source/texk/web2c/luatexdir/image/epdf.h | 4 |
2 files changed, 5 insertions, 0 deletions
diff --git a/Build/source/texk/web2c/luatexdir/ChangeLog b/Build/source/texk/web2c/luatexdir/ChangeLog index 393b117e677..2d30d67b1c3 100644 --- a/Build/source/texk/web2c/luatexdir/ChangeLog +++ b/Build/source/texk/web2c/luatexdir/ChangeLog @@ -1,6 +1,7 @@ 2015-10-07 Akira Kakuto <kakuto@fuk.kindai.ac.jp> * Sync with the upstream trunk. + * image/epdf.h: Support Visual Studio 2010 for log(). 2015-10-05 Akira Kakuto <kakuto@fuk.kindai.ac.jp> diff --git a/Build/source/texk/web2c/luatexdir/image/epdf.h b/Build/source/texk/web2c/luatexdir/image/epdf.h index 1a4cc78c381..6bd9734b9dc 100644 --- a/Build/source/texk/web2c/luatexdir/image/epdf.h +++ b/Build/source/texk/web2c/luatexdir/image/epdf.h @@ -199,7 +199,11 @@ PdfDocument *refMemStreamPdfDocument(char *docstream, unsigned long long streams #define STREAM_CHECKSUM_SIZE 16 // md5 +#if defined(_MSC_VER) // VS 2010 cannot compile log(ULONG_MAX)/log(16) +#define STRSTREAM_CHECKSUM_SIZE 1+((unsigned int)(log((double)ULONG_MAX)/log(16.0))) // djb2 printable digest as hex stream +#else #define STRSTREAM_CHECKSUM_SIZE 1+((unsigned int)(log(ULONG_MAX)/log(16))) // djb2 printable digest as hex stream +#endif #define STREAM_FILE_ID_LEN 2048 // 2048 bytes are enough to make a strong almost-unique name #define STREAM_URI "data:application/pdf," #define STREAM_URI_LEN 21 // length of "data:application/pdf," without final '\0' |