Slight refactor of code initialising memory for argments/environment c-strings

This pull-request is for slightly improved code (arg declared in only block it is used) compared to the previous pull request #7