Port reduction crash fix
Merge pull request #679 from ambarish-prakash/CodeBlockNodePort

Port reduction crash fix