agent: Fix error code check from npth_mutex_init.