]> asedeno.scripts.mit.edu Git - PuTTY.git/blob - unix/ptermm.c
58b42b61580afddd99732d26dd0e0a74c6aa80a3
[PuTTY.git] / unix / ptermm.c
1 /*
2  * pterm main program.
3  */
4
5 #include <stdio.h>
6 #include <stdlib.h>
7
8 #include "putty.h"
9
10 const char *const appname = "pterm";
11
12 /*
13  * Another bunch of temporary stub functions. These ones will want
14  * removing by means of implementing them properly: libcharset
15  * should invent its own sensible format for codepage names and a
16  * means of enumerating them, and printer_enum needs to be dealt
17  * with somehow or other too.
18  */
19
20 char *cp_name(int codepage)
21 {
22     return "";
23 }
24 char *cp_enumerate(int index)
25 {
26     return NULL;
27 }
28 int decode_codepage(char *cp_name)
29 {
30     return -2;
31 }
32
33 Backend *select_backend(Config *cfg)
34 {
35     return &pty_backend;
36 }
37
38 int cfgbox(Config *cfg)
39 {
40     return 1;                          /* no-op in pterm */
41 }
42
43 void cleanup_exit(int code)
44 {
45     exit(code);
46 }
47
48 int process_nonoption_arg(char *arg, Config *cfg)
49 {
50     return 0;                          /* pterm doesn't have any. */
51 }
52
53 char *make_default_wintitle(char *hostname)
54 {
55     return dupstr("pterm");
56 }
57
58 int main(int argc, char **argv)
59 {
60     extern int pt_main(int argc, char **argv);
61     extern void pty_pre_init(void);    /* declared in pty.c */
62
63     cmdline_tooltype = TOOLTYPE_NONNETWORK;
64
65     pty_pre_init();
66
67     return pt_main(argc, argv);
68 }