Fixed some errors (thanks to F Gouget for reporting them).