From the output specifications (5V @ 2.1A) the two adapters appear the same, however, the Tab knows when it's not connnected to it's own charger and does not behave when connected to an iPad charger, how does it know? Is there a signal in the USB that advises the Tab that it's connected to a Tab charger?
The data pins are supplied with various voltages to notify devices what rate to charge at. The standard factory charger will provide the correct voltage to charge at maximum current for a given device. Some 'compatible' chargers will also provide the correct voltages to the data pins, but it would seem this hasn't become an industry standard by the looks.
The industry standard is that both data pins are connected and the charger has a current limit on the power supply at the max it can supply.
Apple did their own thing and have voltages on the pins to signal the adapter wattage and the adapter stays outputting 5v rather than a current limit that will allow that to sag to whatever the device being charged needs.
The current limiting means that funky stuff happens if you try plugging a hub or Y cable into a charger and charge 2 devices off it.