summaryrefslogtreecommitdiff
path: root/src/startup.c
diff options
context:
space:
mode:
authorMichael Jennings <mej@kainx.org>2000-11-16 23:45:01 +0000
committerMichael Jennings <mej@kainx.org>2000-11-16 23:45:01 +0000
commit2b30d160f4c559e83e5d9bcca5ddd9998ec9b72f (patch)
tree921d2c774b281056dc8cb3fc283ecc73bb977493 /src/startup.c
parent1bcfa73217c46e34de776417ded5003625e1705f (diff)
downloadeterm-2b30d160f4c559e83e5d9bcca5ddd9998ec9b72f.tar.gz
Thu Nov 16 16:40:54 PST 2000 Michael Jennings <mej@eterm.org>
VA bought some licenses for Insure++, so I've been using it to audit Eterm. These are just the initial results of the collaboration; there will most likely be more. So far things are looking pretty good. I just wish Insure++ had more helpful messages. I'd really love to be able to track down those reads/writes involving freed pointers that it claims to have found in Imlib2.... I also had to try and make the build work without MMX. I did so; I just hope it still works *with* MMX.... =) SVN revision: 3895
Diffstat (limited to 'src/startup.c')
-rw-r--r--src/startup.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/startup.c b/src/startup.c
index c07eb49..688a0dd 100644
--- a/src/startup.c
+++ b/src/startup.c
@@ -64,7 +64,7 @@ short bg_needs_update = 1;
TermWin_t TermWin;
Display *Xdisplay; /* display */
Colormap cmap;
-const char *display_name = NULL;
+char *display_name = NULL;
unsigned int colorfgbg;
int
@@ -92,8 +92,11 @@ eterm_bootstrap(int argc, char *argv[])
libast_set_program_version(VERSION);
/* Open display, get options/resources and create the window */
- if ((display_name = getenv("DISPLAY")) == NULL)
- display_name = ":0";
+ if (getenv("DISPLAY") == NULL) {
+ display_name = STRDUP(":0");
+ } else {
+ display_name = STRDUP(getenv("DISPLAY"));
+ }
/* This MUST be called before any other Xlib functions */