more changes from Venelin