Fixed memory leak
Tagged version 0.5.17