Skip to content

Commit 5a05f67

Browse files
committed
[SPARK-52792][CORE][FOLLOWUP] Remove redundant condition check
### What changes were proposed in this pull request? This PR is a follow-up to clean up a redundant condition check. ### Why are the changes needed? To remove a redundant condition - https://github.com/apache/spark/pull/51476/files#r2209040510 ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Pass the CIs. ### Was this patch authored or co-authored using generative AI tooling? No. Closes #51524 from dongjoon-hyun/SPARK-52792. Authored-by: Dongjoon Hyun <[email protected]> Signed-off-by: Dongjoon Hyun <[email protected]>
1 parent 5e6b4df commit 5a05f67

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

common/network-common/src/main/java/org/apache/spark/network/server/TransportServer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ private void init(String hostToBind, int portToBind) {
105105
conf.getModuleName() + "-server");
106106

107107
String name = System.getProperty("os.name");
108-
boolean isNotWindows = 7 > name.length() || !name.regionMatches(true, 0, "Windows", 0, 7);
108+
boolean isNotWindows = !name.regionMatches(true, 0, "Windows", 0, 7);
109109
bootstrap = new ServerBootstrap()
110110
.group(bossGroup, workerGroup)
111111
.channel(NettyUtils.getServerChannelClass(ioMode))

0 commit comments

Comments
 (0)