It's difficult to say for sure, as it might depend on what wparam/lparam are meant for, and if lparams is supposed to be a signed integer, we need to sign extend it.
Maybe a safe choice here would be to use the WPARAM/LPARAM types instead, which would avoid sign-extending wparam as WPARAM is unsigned, but still sign extend lparam.
Which message are you seeing this with?