Skip to content

Commit ad675c4

Browse files
author
Artyom Abakumov
committed
Fix rest c4018 warnings
1 parent d4fc7eb commit ad675c4

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

src/burp/restore.epp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12365,7 +12365,7 @@ bool RestoreRelationTask::fileReader(Item& item)
1236512365
const FB_SSIZE_T attLen = 1 + (tdgbl->gbl_sw_transportable ? 12 : 6);
1236612366
const FB_SSIZE_T overhead = tdgbl->gbl_sw_compress ? (len / 127 + 1) : 0;
1236712367

12368-
if (len + attLen + overhead > space)
12368+
if (static_cast<FB_SSIZE_T>(len) + attLen + overhead > space)
1236912369
{
1237012370
if (ioBuf)
1237112371
{

src/jrd/inf.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -785,7 +785,7 @@ void INF_database_info(thread_db* tdbb,
785785
length = gds__vax_integer(items, 2);
786786
items += 2;
787787

788-
if (end_items - items >= length)
788+
if (static_cast<ULONG>(end_items - items) >= length)
789789
{
790790
pageNum = gds__vax_integer(items, length);
791791
items += length;

src/jrd/sqz.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -558,7 +558,7 @@ ULONG Difference::apply(ULONG diffLength, ULONG outLength, UCHAR* const output)
558558
BUGCHECK(177); // msg 177 applied differences will not fit in record
559559
}
560560

561-
const auto length = p - output;
561+
const FB_UINT64 length = p - output;
562562

563563
if (length > outLength)
564564
BUGCHECK(177); // msg 177 applied differences will not fit in record

src/yvalve/why.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1424,7 +1424,7 @@ static void setTextType(XSQLVAR* var, unsigned charSet)
14241424
static int sqldaTruncateString(char* buffer, FB_SIZE_T size, const char* s)
14251425
{
14261426
int ret = fb_utils::snprintf(buffer, size, "%s", s);
1427-
return MIN(ret, size - 1);
1427+
return MIN(ret, static_cast<int>(size - 1));
14281428
}
14291429

14301430
// Describe parameters metadata in an sqlda.

0 commit comments

Comments
 (0)