Changes for port snapping

Fix for port snapping