diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2021-11-13 12:19:49 +0200 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2021-11-20 10:58:33 +0100 |
commit | 867abf5b8eff8733dd7ad020d16724ed8eda3885 (patch) | |
tree | ec7b00baa69a7f213afe701524523f1eb3b79a41 /extensions | |
parent | 40b40b74aae7e2a98dc964286baf499ecd1ae10b (diff) |
Drop unused variables - again
This re-instates commit a339ebca55f53db5f0b72b26fcfbb3aaa2b2a825
"Drop unused variables", that was accidentally reverted in
commit 1b6e3efe964eec9110e656a8242f6f4d8b5e7f7e "Simplify
m_aAppId initialization".
Change-Id: Ib65500cc0b0b5c27425f76e358f2d786a7faac09
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125583
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'extensions')
-rw-r--r-- | extensions/source/scanner/twain32shim.cxx | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/extensions/source/scanner/twain32shim.cxx b/extensions/source/scanner/twain32shim.cxx index 254ed747281d..ab99ab332572 100644 --- a/extensions/source/scanner/twain32shim.cxx +++ b/extensions/source/scanner/twain32shim.cxx @@ -383,17 +383,15 @@ void ImpTwain::ImplXfer() { TW_IMAGEINFO aInfo; HANDLE hDIB = nullptr; - TW_INT32 nWidth, nHeight, nXRes, nYRes; + TW_INT32 nXRes, nYRes; if (m_pDSM(&m_aAppId, &m_aSrcId, DG_IMAGE, DAT_IMAGEINFO, MSG_GET, &aInfo) == TWRC_SUCCESS) { - nWidth = aInfo.ImageWidth; - nHeight = aInfo.ImageLength; nXRes = FixToInt32(aInfo.XResolution); nYRes = FixToInt32(aInfo.YResolution); } else - nWidth = nHeight = nXRes = nYRes = -1; + nXRes = nYRes = -1; switch (m_pDSM(&m_aAppId, &m_aSrcId, DG_IMAGE, DAT_IMAGENATIVEXFER, MSG_GET, &hDIB)) { @@ -413,7 +411,7 @@ void ImpTwain::ImplXfer() { if (LPVOID pBmpMem = GlobalLock(hGlob)) { - if ((nXRes != -1) && (nYRes != -1) && (nWidth != -1) && (nHeight != -1)) + if ((nXRes != -1) && (nYRes != -1)) { // set resolution of bitmap BITMAPINFOHEADER* pBIH = static_cast<BITMAPINFOHEADER*>(pBmpMem); |