diff options
author | Timo Sirainen <cras@irssi.org> | 2000-11-17 18:02:17 +0000 |
---|---|---|
committer | cras <cras@dbcabf3a-b0e7-0310-adc4-f8d773084564> | 2000-11-17 18:02:17 +0000 |
commit | df3da57de2bfe9f8be948f1e39450afbff7feac4 (patch) | |
tree | f1b7b5b79e0ddbb6dbc0d4c0d9d5f6ebec53803a /src/fe-text/statusbar-items.c | |
parent | 7adca508b12b4b3be6f9a12fbb251c6cd8a666bf (diff) | |
download | irssi-df3da57de2bfe9f8be948f1e39450afbff7feac4.zip |
Don't crash if MAIL environment isn't set.
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@848 dbcabf3a-b0e7-0310-adc4-f8d773084564
Diffstat (limited to 'src/fe-text/statusbar-items.c')
-rw-r--r-- | src/fe-text/statusbar-items.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/fe-text/statusbar-items.c b/src/fe-text/statusbar-items.c index 78a3b5f6..558c34a3 100644 --- a/src/fe-text/statusbar-items.c +++ b/src/fe-text/statusbar-items.c @@ -599,6 +599,8 @@ static int get_mail_count(void) int count; fname = g_getenv("MAIL"); + if (fname == NULL) return 0; + if (stat(fname, &statbuf) != 0) { mail_last_mtime = -1; mail_last_size = -1; |