set_maxchild (nchild)
     int nchild;
{
  static int lmaxchild = -1;

  if (lmaxchild < 0)
    lmaxchild = getmaxchild ();
  if (lmaxchild < 0)
    lmaxchild = DEFAULT_CHILD_MAX;

  /* Clamp value we set.  Minimum is what Posix requires, maximum is defined
     above as MAX_CHILD_MAX. */
  if (nchild < lmaxchild)
    nchild = lmaxchild;
  else if (nchild > MAX_CHILD_MAX)
    nchild = MAX_CHILD_MAX;

  js.c_childmax = nchild;
}
set_maxchild (nchild)
     int nchild;
{
  static int lmaxchild = -1;

  if (lmaxchild < 0)
    lmaxchild = getmaxchild ();
  if (lmaxchild < 0)
    lmaxchild = DEFAULT_CHILD_MAX;

   
  if (nchild < lmaxchild)
    nchild = lmaxchild;
  else if (nchild > MAX_CHILD_MAX)
    nchild = MAX_CHILD_MAX;

  js.c_childmax = nchild;
}