ctdb-tools: Fix sort order of "ctdb ip" output
authorMartin Schwenke <martin@meltin.net>
Tue, 6 Dec 2016 22:23:02 +0000 (09:23 +1100)
committerAmitay Isaacs <amitay@samba.org>
Fri, 16 Dec 2016 07:42:32 +0000 (08:42 +0100)
commit7bcef2f0e2969551134e0d72f0956685eeec10a3
tree06b3cfdbac2f4c2f4d32df6f1b7e8cf21060c842
parent3845ff6349421560bdcf9ba13467b2418205cd96
ctdb-tools: Fix sort order of "ctdb ip" output

The new hash-table-based method of merging the IP information does not
sort, whereas the RB-tree method implicitly sorted.  This probably
only really matters for the "all" case, but sort regardless to ensure
consistent output format.

Sorting has to be done here instead of when printing to ensure
consistency between ip[] and ipinfo[].

No longer reverse the sort order.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=12470

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
ctdb/tools/ctdb.c