Incorrect packet handling in SMBClient MacOS 26.

SMBClient-593 introduces a crtitical bug.

When reading and writing data at high volume, the SMBClient no longer properly receives and handle responses from the server.

In some cases, the client mishandles the response packet and the following errors are seen in the logs:

2025-12-02 21:36:04.774772-0700  localhost kernel[0]: (smbfs) smb2_smb_parse_write_one: Bad struct size: 0
2025-12-02 21:36:04.774776-0700  localhost kernel[0]: (smbfs) smb2_smb_write: smb2_smb_read_write_async failed with an error 72
2025-12-02 21:36:04.774777-0700  localhost kernel[0]: (smbfs) smbfs_do_strategy: file.txt: WRITE failed with an error of 72

In other cases, the client mishandles the response packet and becomes completely unresponsive, unable to send or receive additional messages, and a forced shutdown of the computer is required to recover.

This bug is only present on macos 26. We believe the operative change is in the latest commit, SMBClient-593 beginning at line now 3011 in smb_iod.c. The issue seems to be a race, and occurs much more frequently once throughput exceeds around 10Gbps, and again more frequently above 20Gbps.

Incorrect packet handling in SMBClient MacOS 26.
 
 
Q