added (untested) ipSort