Added some changes that I am using in http://sourceforge.net/projects/pandora/ .