treewide: Use {ug}id_valid() instead of comparing with INVALID_{U,G}ID
This test is equivalent, and makes it so that {u,g}id_eq() can be
changed to return flase for comparison between two invalid ids.
Signed-off-by: Seth Forshee <sforshee@digitalocean.com>