Hannah was a childhood pet of Dave Lister.
Dave Lister had lost all the photographs of his adoptive father, who died when Lister was six. He did still however have a photograph of him walking the family dog Hannah, but only his father's beige overcoat and gloved hand could be seen, holding Hannah's leash.
Three million years later, in the sleeping quarters aboard Red Dwarf, Lister showed some of his old photographs to the Cat. Believing Hannah to be Lister's biological father, and not knowing what dogs were, the Cat said that it was no wonder Lister was so ugly.
The Cat says that would chase Hannah if the dog were still around, but Lister tells the Cat that dogs are "giant" with teeth as big as a leg. The Cat still says he'd chase her anyway, before slinking off terrified.