/**********************************************************************
 * do_ping.c  -- SS command to ping server
 * tty lucy client using SS library
 *
 * $Author: brlewis $
 * $Source$
 * $Header$
 *
 * Copyright 1992 by the Massachusetts Institute of Technology.
 *
 * For copying and distribution information, please see the file
 * <mit-copyright.h>.
 **********************************************************************/
#include <mit-copyright.h>

#ifndef lint
static char rcsid_do_ping_c[] = "$Header$";
#endif /* lint */

#ifndef POSIX
#include <sys/types.h>
#endif /* POSIX */
#include <time.h>
#include <ss/ss.h>
#include <lucy/lucy.h>
#include "config.h"

void
do_ping(argc, argv)
     int argc;
     char *argv[];
{
  long code;
  time_t t;

  if (code=luc_ping(&t))
    com_err(argv[0], code, "(%s)", luv_context);
  else
    printf("Server %s running lucyd since %s\n", luv_host, ctime(&t));
  return;
}
