mirror of https://github.com/acidanthera/audk.git
fix the bug of calculating subnetmask prefix length. It is a regression issue, which incorrectly take "&" operation as "&&"
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7639 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
76f1dde2c4
commit
d5893e0b04
|
@ -94,7 +94,7 @@ IScsiGetSubnetMaskPrefixLength (
|
|||
//
|
||||
ReverseMask = ~ReverseMask;
|
||||
|
||||
if ((ReverseMask != 0) & ((ReverseMask + 1) != 0)) {
|
||||
if ((ReverseMask & (ReverseMask + 1)) != 0) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue