X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=misc.c;h=cf97c049a176ea545a69f4810f4481c4d296d5fa;hb=a1f3b7a358adaa7c2a98359cd0373aa823eeb14b;hp=8f728eea214f3b52e0d9015fafdf562928a0e9ea;hpb=7aba365ca9388779f161f277347d7130f0dc7a40;p=PuTTY.git diff --git a/misc.c b/misc.c index 8f728eea..cf97c049 100644 --- a/misc.c +++ b/misc.c @@ -635,21 +635,21 @@ void debug_memdump(void *buf, int len, int L) #endif /* def DEBUG */ /* - * Determine whether or not a Config structure represents a session - * which can sensibly be launched right now. + * Determine whether or not a Conf represents a session which can + * sensibly be launched right now. */ -int cfg_launchable(const Config *cfg) +int conf_launchable(Conf *conf) { - if (cfg->protocol == PROT_SERIAL) - return cfg->serline[0] != 0; + if (conf_get_int(conf, CONF_protocol) == PROT_SERIAL) + return conf_get_str(conf, CONF_serline)[0] != 0; else - return cfg->host[0] != 0; + return conf_get_str(conf, CONF_host)[0] != 0; } -char const *cfg_dest(const Config *cfg) +char const *conf_dest(Conf *conf) { - if (cfg->protocol == PROT_SERIAL) - return cfg->serline; + if (conf_get_int(conf, CONF_protocol) == PROT_SERIAL) + return conf_get_str(conf, CONF_serline); else - return cfg->host; + return conf_get_str(conf, CONF_host); }