aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/upas
diff options
context:
space:
mode:
authorrsc <devnull@localhost>2006-06-30 04:53:51 +0000
committerrsc <devnull@localhost>2006-06-30 04:53:51 +0000
commit141d60097223f56e82ae3c45c90d6453cdd11cba (patch)
tree7563478da98b19056641a2b42e98d5fd7ec26995 /src/cmd/upas
parente6c443621bbcc8929f4c08648bfd1ab6014b66b9 (diff)
downloadplan9port-141d60097223f56e82ae3c45c90d6453cdd11cba.tar.gz
plan9port-141d60097223f56e82ae3c45c90d6453cdd11cba.tar.bz2
plan9port-141d60097223f56e82ae3c45c90d6453cdd11cba.zip
use file names for attachments
Diffstat (limited to 'src/cmd/upas')
-rw-r--r--src/cmd/upas/nfs/box.h1
-rw-r--r--src/cmd/upas/nfs/fs.c5
-rw-r--r--src/cmd/upas/nfs/imap.c3
3 files changed, 5 insertions, 4 deletions
diff --git a/src/cmd/upas/nfs/box.h b/src/cmd/upas/nfs/box.h
index da2b0ab5..9ca3b8f9 100644
--- a/src/cmd/upas/nfs/box.h
+++ b/src/cmd/upas/nfs/box.h
@@ -93,6 +93,7 @@ struct Part
char* desc;
char* encoding;
char* charset;
+ char* filename;
char* raw;
char* rawheader;
char* rawbody;
diff --git a/src/cmd/upas/nfs/fs.c b/src/cmd/upas/nfs/fs.c
index 71d33ec1..228b53f6 100644
--- a/src/cmd/upas/nfs/fs.c
+++ b/src/cmd/upas/nfs/fs.c
@@ -604,9 +604,8 @@ filedata(int type, Box *box, Msg *msg, Part *part, char **pp, int *len, int *fre
fmtprint(&fmt, "type %s\n", part->type);
if(part->lines)
fmtprint(&fmt, "lines %d\n", part->lines);
- /* fmtprint(&fmt, "disposition %s\", ""); */
- /* fmtprint(&fmt, "filename %s\n", ""); */
- /* fmtprint(&fmt, "digest %s\n", ""); */
+ if(part->filename)
+ fmtprint(&fmt, "filename %s\n", part->filename);
s = fmtstrflush(&fmt);
if(s == nil)
s = estrdup("");
diff --git a/src/cmd/upas/nfs/imap.c b/src/cmd/upas/nfs/imap.c
index 409544f0..1caa97b2 100644
--- a/src/cmd/upas/nfs/imap.c
+++ b/src/cmd/upas/nfs/imap.c
@@ -1458,7 +1458,8 @@ static struct {
char *name;
int offset;
} paramtab[] = {
- "charset", offsetof(Part, charset)
+ "charset", offsetof(Part, charset),
+ "name", offsetof(Part, filename)
};
static void