net: Fix references to out-of-scope variables in put_cmsg_compat()

https://github.com/engstk/hammerhead-5.0/commit/4e1051458731c13535ea7577d654c77ff51263f6#diff-a11f9e55f4488df1ac46c6d08728b197R232