pshash_delindex (psi)
     ps_index_t psi;
{
  struct pidstat *ps;

  ps = &bgpids.storage[psi];
  if (ps->pid == NO_PID)
    return;

  if (ps->bucket_next != NO_PID)
    bgpids.storage[ps->bucket_next].bucket_prev = ps->bucket_prev;
  if (ps->bucket_prev != NO_PID)
    bgpids.storage[ps->bucket_prev].bucket_next = ps->bucket_next;
  else
    *(pshash_getbucket (ps->pid)) = ps->bucket_next;
}
pshash_delindex (psi)
     ps_index_t psi;
{
  struct pidstat *ps;

  ps = &bgpids.storage[psi];
  if (ps->pid == NO_PID)
    return;

  if (ps->bucket_next != NO_PID)
    bgpids.storage[ps->bucket_next].bucket_prev = ps->bucket_prev;
  if (ps->bucket_prev != NO_PID)
    bgpids.storage[ps->bucket_prev].bucket_next = ps->bucket_next;
  else
    *(pshash_getbucket (ps->pid)) = ps->bucket_next;
}