Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit45aae8e

Browse files
committed
Suppress compiler warning.
Some buildfarm members are showing "comparison is always false due tolimited range of data type" complaints on this test, so #ifdef it outon machines with 32-bit int.
1 parent9c50372 commit45aae8e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

‎src/timezone/zic.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1179,11 +1179,14 @@ gethms(char const * string, char const * errstring, bool signable)
11791179
error("%s",errstring);
11801180
return0;
11811181
}
1182-
if (ZIC_MAX /SECSPERHOUR< (zic_t)hh)
1182+
/* Some compilers warn that this test is unsatisfiable for 32-bit ints */
1183+
#ifINT_MAX>PG_INT32_MAX
1184+
if (ZIC_MAX /SECSPERHOUR<hh)
11831185
{
11841186
error(_("time overflow"));
11851187
return0;
11861188
}
1189+
#endif
11871190
if (noise&& (hh>HOURSPERDAY||
11881191
(hh==HOURSPERDAY&& (mm!=0||ss!=0))))
11891192
warning(_("values over 24 hours not handled by pre-2007 versions of zic"));

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp