added comments on re-use of third party code, small fixes on the way