Fix listfiles.sh script producing an extra line when CDPATH is set.

The shell causes `cd $1` to print the current directory when CDPATH is
set. Th extra printed line causes the produced output jar to be broken.