I note three things.
== HERE BE SPOILERS! ==
First, it has a major plausibility problem, in that O'Shaughnessy, who was willing to manipulate Archer into killing Thursby and who killed Archer outright, could more easily have just killed Thursby outright, and never got entangled with Archer. The internally senseless convolution is just a device to involve Spade and ultimately to motivate the amoral Spade into turning on O'Shaughnessy.
Second, the device of pushing Spade to strip-search O'Shaughnessy creates a context in which it can be strongly suggested that O'Shaughnessy truly loved Spade. That device was just wasted in the first movie adaptation.
Third, each of the three movie adaptations is in some ways more faithful to the novel than each of the other two movie adaptations.