This seems quite kludgy.Another alternative is to handle WM_NCHITTEST. In it call DefWindowProc to get the current hit-test value, if it's either of HTRIGHT or HTLEFT then return HTCLIENT or HTBORDER and the cursor won't change to the sizing one, thus disabling it.
If I go to the Menu in the upper left (Alt+Space) and hit resize, does it still prevent me from resizing? I'd almost bet not, but I'm in Linux at the moment.