aとbを交換する場合は、

swap(struct man *a, struct man *b)
{

struct man* a_prev = a->prev;
struct man* a_next = a->next;
struct man* b_prev = b->prev;
struct man* b_next = a->next;

a_prev->next = b;
b->next = a_next;

b_prev->next = a;
a->next = b_next;

b->prev = a_prev;
a_next->prev = b;

a->prev = b_prev;
b_next->prev = a;

}
じゃね?

加えて実際には、端にあるノードの場合の処理が必要だが。