conf_launchable.c 344 B

123456789101112131415
  1. /*
  2. * Determine whether or not a Conf represents a session which can
  3. * sensibly be launched right now.
  4. */
  5. #include "putty.h"
  6. bool conf_launchable(Conf *conf)
  7. {
  8. if (conf_get_int(conf, CONF_protocol) == PROT_SERIAL)
  9. return conf_get_str(conf, CONF_serline)[0] != 0;
  10. else
  11. return conf_get_str(conf, CONF_host)[0] != 0;
  12. }