It should be fine.
Assuming it has something illegal (like, illegal location of finding it, moveset etc.) then you can't enter it into the GTS or Wi-Fi battles.
If it bothers you to the point where you want to release it, feel free to do so. Hacked Pokemon can basically do anything, however it shouldn't do too much harm.
Hope I helped. :)
Source: Experience