PDF: tolerate slightly non-standard indexed colorspace definitions (fixes issue 2477)