https://issues.jenkins-ci.org/browse/JENKINS-5347

import patch provided in issue in latest version

The patch on 1.50 is deployed successfully in our jenkins server.