Should bad prior work be ignored, or cited and criticised?
Negative citations is what you describe. It is something of a fallacy of the system that a paper may get many citations and therefore seems important when it is clearly sub-par and is referenced in a negative connotation.

Seen objectively, one should give credit where it is due. If someone was first to realize something then that is the origin of the idea (in official terms), how good or bad the paper is, is irrelevant. In some cases first discoveries may just be gut feelings and not well-founded. 

I sometimes have to bite my lip when I reference some papers because I really do not think they deserve it (because I know the background) but realize there are no two ways about it. You can of course chose not to reference it, as you have the freedom to chose what we cite, but you may end up getting reviews asking you to add it (if it is something key).

In some cases it is possible to provide objective criticism of a paper. The problem is that the shortcomings will have to be clear.