summaryrefslogtreecommitdiff
path: root/mh
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2008-07-19 10:06:50 +0000
committerSergey Poznyakoff <gray@gnu.org.ua>2008-07-19 10:06:50 +0000
commit583f4579198b2ac530b4c52f078ff9cc02616f61 (patch)
treee2dc199bfb4875940467ccb4d5cc16314a2821d1 /mh
parente5b11edf9793f392bc9da33ddc4fd0639376df43 (diff)
downloadmailutils-583f4579198b2ac530b4c52f078ff9cc02616f61.tar.gz
mailutils-583f4579198b2ac530b4c52f078ff9cc02616f61.tar.bz2
Minor fix.
* mh/mhn.c (normalize_path): First arg is const char *. (store_handler): Avoid unnecessary allocations (and coredumps, if mhn-storage profile is not set.
Diffstat (limited to 'mh')
-rw-r--r--mh/mhn.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/mh/mhn.c b/mh/mhn.c
index 26ac0d071..c871c4200 100644
--- a/mh/mhn.c
+++ b/mh/mhn.c
@@ -1512,7 +1512,7 @@ mhn_show ()
/* ***************************** Store Mode ****************************** */
char *
-normalize_path (char *cwd, char *path)
+normalize_path (const char *cwd, char *path)
{
int len;
char *p;
@@ -1615,7 +1615,7 @@ store_handler (mu_message_t msg, msg_part_t part, char *type, char *encoding,
&& argv[i][0] == '='
&& ++i < argc)
{
- name = normalize_path (xstrdup (dir), argv[i]);
+ name = normalize_path (dir, argv[i]);
break;
}
}
@@ -1639,7 +1639,7 @@ store_handler (mu_message_t msg, msg_part_t part, char *type, char *encoding,
&& argv[i][0] == '='
&& ++i < argc)
{
- name = normalize_path (xstrdup (dir), argv[i]);
+ name = normalize_path (dir, argv[i]);
break;
}
}

Return to:

Send suggestions and report system problems to the System administrator.