2003-03-29 22:52:50 +03:00
|
|
|
/*
|
|
|
|
* pterm main program.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <stdio.h>
|
2003-04-01 22:10:25 +04:00
|
|
|
#include <stdlib.h>
|
2003-03-29 22:52:50 +03:00
|
|
|
|
|
|
|
#include "putty.h"
|
|
|
|
|
2003-04-05 20:05:00 +04:00
|
|
|
const char *const appname = "pterm";
|
2003-04-09 22:46:45 +04:00
|
|
|
const int use_event_log = 0; /* pterm doesn't need it */
|
2003-04-12 21:37:15 +04:00
|
|
|
const int new_session = 0, saved_sessions = 0; /* or these */
|
2003-04-05 20:05:00 +04:00
|
|
|
|
2003-03-29 22:52:50 +03:00
|
|
|
Backend *select_backend(Config *cfg)
|
|
|
|
{
|
|
|
|
return &pty_backend;
|
|
|
|
}
|
|
|
|
|
|
|
|
int cfgbox(Config *cfg)
|
|
|
|
{
|
2003-04-26 18:35:34 +04:00
|
|
|
/*
|
|
|
|
* This is a no-op in pterm, except that we'll ensure the
|
|
|
|
* protocol is set to -1 to inhibit the useless Connection
|
|
|
|
* panel in the config box.
|
|
|
|
*/
|
|
|
|
cfg->protocol = -1;
|
|
|
|
return 1;
|
2003-03-29 22:52:50 +03:00
|
|
|
}
|
|
|
|
|
2003-04-01 22:10:25 +04:00
|
|
|
void cleanup_exit(int code)
|
|
|
|
{
|
|
|
|
exit(code);
|
|
|
|
}
|
|
|
|
|
2003-03-31 16:10:53 +04:00
|
|
|
int process_nonoption_arg(char *arg, Config *cfg)
|
|
|
|
{
|
|
|
|
return 0; /* pterm doesn't have any. */
|
|
|
|
}
|
|
|
|
|
2003-03-31 15:42:45 +04:00
|
|
|
char *make_default_wintitle(char *hostname)
|
|
|
|
{
|
|
|
|
return dupstr("pterm");
|
|
|
|
}
|
|
|
|
|
2003-03-29 22:52:50 +03:00
|
|
|
int main(int argc, char **argv)
|
|
|
|
{
|
|
|
|
extern int pt_main(int argc, char **argv);
|
|
|
|
extern void pty_pre_init(void); /* declared in pty.c */
|
|
|
|
|
2003-03-31 16:10:53 +04:00
|
|
|
cmdline_tooltype = TOOLTYPE_NONNETWORK;
|
2003-04-26 18:35:34 +04:00
|
|
|
default_protocol = -1;
|
2003-03-31 16:10:53 +04:00
|
|
|
|
2003-03-29 22:52:50 +03:00
|
|
|
pty_pre_init();
|
|
|
|
|
|
|
|
return pt_main(argc, argv);
|
|
|
|
}
|