netlink-socket: Fix a couple of compilation warnings.

Reported-by: Gurucharan Shetty <gshetty@nicira.com>
Signed-off-by: Nithin Raju <nithin@vmware.com>
Acked-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
Tested-by: Alin Gabriel Serdean <aserdean@cloudbasesolutions.com>
[blp@nicira.com replaced conventional cast by CONST_CAST]
Signed-off-by: Ben Pfaff <blp@nicira.com>