If God considered slavery to be a "wrong" He would have prohibited it -- that's the point.
So why do we think slavery is wrong?
The bible is pretty good at spelling out what's right and what's wrong. It never says that slavery is wrong. In fact ...
leviticus
25:44 Both thy bondmen, and thy bondmaids, which thou shalt have, shall be of the heathen that are round about you; of them shall ye buy bondmen and bondmaids.25:45 Moreover of the children of the strangers that do sojourn among you, of them shall ye buy, and of their families that are with you, which they begat in your land: and they shall be your possession.
25:46 And ye shall take them as an inheritance for your children after you, to inherit them for a possession; they shall be your bondmen for ever: but over your brethren the children of Israel, ye shall not rule one over another with rigour.