From 3cecadbddd137770552ceaad018336e195233e4a Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Tue, 21 Jun 2016 10:12:27 +0100 Subject: Related: tdf#92478 speculative win64 scanning fix MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit TWAIN-2.3-Spec.pdf says... All TWAIN 2.x Sources must be prepared to work with either TWAINDSM.DLL or TWAIN_32.DLL, which may still be used by older Applications. The TWAIN DSM is a shared library named TWAINDSM.DLL. There is a 32-bit and a 64-bit version of this file. Change-Id: I047d872271573a5b2efc3ee2af4ecfc4e142a2b2 Reviewed-on: https://gerrit.libreoffice.org/26541 Tested-by: Jenkins Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- extensions/source/scanner/scanwin.cxx | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'extensions/source') diff --git a/extensions/source/scanner/scanwin.cxx b/extensions/source/scanner/scanwin.cxx index fb4fc1592579..7075f7632e3d 100644 --- a/extensions/source/scanner/scanwin.cxx +++ b/extensions/source/scanner/scanwin.cxx @@ -59,10 +59,12 @@ using namespace ::com::sun::star; #define PTWAINMSG MSG* #define FIXTODOUBLE( nFix ) ((double)nFix.Whole+(double)nFix.Frac/65536.) #define FIXTOLONG( nFix ) ((long)floor(FIXTODOUBLE(nFix)+0.5)) - -#if defined(_WIN32) -#define TWAIN_LIBNAME "TWAIN_32.DLL" #define TWAIN_FUNCNAME "DSM_Entry" + +#if defined(TWH_64BIT) +# define TWAIN_LIBNAME "TWAINDSM.DLL" +#else +# define TWAIN_LIBNAME "TWAIN_32.DLL" #endif enum TwainState -- cgit