… | |
… | |
21 | *----------------------------------------------------------------------*/ |
21 | *----------------------------------------------------------------------*/ |
22 | |
22 | |
23 | #include "../config.h" |
23 | #include "../config.h" |
24 | #include "rxvt.h" |
24 | #include "rxvt.h" |
25 | |
25 | |
|
|
26 | #include <cstdlib> |
|
|
27 | #include <cstring> |
|
|
28 | |
26 | int |
29 | int |
27 | main (int argc, const char *const *argv) |
30 | main (int argc, const char *const *argv) |
28 | try |
31 | try |
29 | { |
32 | { |
30 | rxvt_init_signals (); |
33 | rxvt_init (); |
|
|
34 | |
|
|
35 | stringvec *envv = new stringvec; |
|
|
36 | |
|
|
37 | for (char **var = environ; *var; var++) |
|
|
38 | envv->push_back (strdup (*var)); |
|
|
39 | |
|
|
40 | envv->push_back (0); |
31 | |
41 | |
32 | rxvt_term *t = new rxvt_term; |
42 | rxvt_term *t = new rxvt_term; |
33 | |
43 | |
34 | if (!t->init (argc, argv)) |
44 | if (!t->init (argc, argv, envv)) |
35 | return EXIT_FAILURE; |
45 | return EXIT_FAILURE; |
36 | |
46 | |
37 | iom.loop (); |
47 | io_manager::loop (); |
38 | |
48 | |
39 | return EXIT_SUCCESS; |
49 | return EXIT_SUCCESS; |
40 | } |
50 | } |
41 | catch (const class rxvt_failure_exception &e) |
51 | catch (const class rxvt_failure_exception &e) |
42 | { |
52 | { |