summaryrefslogtreecommitdiff
path: root/sal
diff options
context:
space:
mode:
authorOnur Yilmaz <onuryilmaz0750@gmail.com>2020-01-27 11:46:12 +0300
committerStephan Bergmann <sbergman@redhat.com>2020-01-28 16:53:27 +0100
commitb44ad15cd78892f2f1d7fe83ccda9fc41dc9c9a5 (patch)
treeb8e370ee7c51a46857807044203ea45d26a1bcf9 /sal
parent77ce7835e7e46290d8d3204cfa2e6d1ad39a0ee4 (diff)
tdf#96505: Get rid of cargo cult long integer literals
I checked return values. Long variables didn't affect the calculation. Change-Id: Ia3713eedf275de71b1096d1fe7e22da012a7f94e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87493 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sal')
-rw-r--r--sal/osl/unx/profile.cxx4
-rw-r--r--sal/osl/unx/socket.cxx4
2 files changed, 4 insertions, 4 deletions
diff --git a/sal/osl/unx/profile.cxx b/sal/osl/unx/profile.cxx
index b7bc5771fd64..e2cca48ab8c6 100644
--- a/sal/osl/unx/profile.cxx
+++ b/sal/osl/unx/profile.cxx
@@ -1029,11 +1029,11 @@ static bool OslProfile_rewindFile(osl_TFile* pFile, bool bTruncate)
{
pFile->m_pReadPtr = pFile->m_ReadBuf + sizeof(pFile->m_ReadBuf);
- bRet = (lseek(pFile->m_Handle, SEEK_SET, 0L) == 0);
+ bRet = (lseek(pFile->m_Handle, SEEK_SET, 0) == 0);
if (bTruncate)
{
- bRet &= (ftruncate(pFile->m_Handle, 0L) == 0);
+ bRet &= (ftruncate(pFile->m_Handle, 0) == 0);
}
}
diff --git a/sal/osl/unx/socket.cxx b/sal/osl/unx/socket.cxx
index 5db922e7674d..d3b192f4e1f1 100644
--- a/sal/osl/unx/socket.cxx
+++ b/sal/osl/unx/socket.cxx
@@ -1404,7 +1404,7 @@ oslSocketResult SAL_CALL osl_connectSocketTo(oslSocket pSocket,
{
/* divide milliseconds into seconds and microseconds */
tv.tv_sec= pTimeout->Seconds;
- tv.tv_usec= pTimeout->Nanosec / 1000L;
+ tv.tv_usec= pTimeout->Nanosec / 1000;
}
/* select */
@@ -2217,7 +2217,7 @@ sal_Int32 SAL_CALL osl_demultiplexSocketEvents(oslSocketSet IncomingSet,
{
/* non-blocking call */
tv.tv_sec = pTimeout->Seconds;
- tv.tv_usec = pTimeout->Nanosec / 1000L;
+ tv.tv_usec = pTimeout->Nanosec / 1000;
}
/* get max handle from all sets */