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

Commit2d1f3bc

Browse files
committed
Fix some 32-bit shift warnings in MSVC
7b37823 widened AclMode to 64 bits which resulted in 3 new additionalwarnings on MSVC. Here we make use of UINT64CONST to reassure thecompiler that we do intend the bit shift expression to yield a 64-bitresult.Discussion:https://postgr.es/m/CAApHDvo=pn01Y_3zASZZqn+cotF1c4QFCwWgk6MiF0VscaE5ug@mail.gmail.com
1 parentec5affd commit2d1f3bc

File tree

1 file changed

+3
-3
lines changed
  • src/backend/utils/adt

1 file changed

+3
-3
lines changed

‎src/backend/utils/adt/acl.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -626,9 +626,9 @@ aclitemout(PG_FUNCTION_ARGS)
626626

627627
for (i=0;i<N_ACL_RIGHTS;++i)
628628
{
629-
if (ACLITEM_GET_PRIVS(*aip)& (1 <<i))
629+
if (ACLITEM_GET_PRIVS(*aip)& (UINT64CONST(1) <<i))
630630
*p++=ACL_ALL_RIGHTS_STR[i];
631-
if (ACLITEM_GET_GOPTIONS(*aip)& (1 <<i))
631+
if (ACLITEM_GET_GOPTIONS(*aip)& (UINT64CONST(1) <<i))
632632
*p++='*';
633633
}
634634

@@ -1786,7 +1786,7 @@ aclexplode(PG_FUNCTION_ARGS)
17861786
break;
17871787
}
17881788
aidata=&aidat[idx[0]];
1789-
priv_bit=1 <<idx[1];
1789+
priv_bit=UINT64CONST(1) <<idx[1];
17901790

17911791
if (ACLITEM_GET_PRIVS(*aidata)&priv_bit)
17921792
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp