On old cooking ranges, the bottom of the kettle would become black over time, with standing for most of its time on a hot plate. Similarly, any cooking pots would become equally black, hence the notion of one degrading the other for its appearence, which is identical to that of the caller. This has expanded into general use, to mean criticising someone for doing what the critic does equally. Personally I prfefer the more modern version - "That's a pot and kettle coincidence!"