[PATCH] Standardize socket family checks with proper macro