clone from https://github.com/biessek/golang-ico fix reader.go line 131 from https://github.com/goguardian/goico/commit/42b971b459e36f224b22924d0505fa3cdb86ed56