- (if (or part-missing
- (not (y-or-n-p "Merge partials?")))
- (progn
- (kill-buffer buffer)
- (mime/decode-message/partial-region beg end cal))
- (progn
- (set-buffer subject-buf)
- (setq part-missing (mime/gp:part-missing-p subject-id (string-to-int total)))
- (if part-missing
- (progn
- (kill-buffer buffer)
- (error "Couldn't find part %d" part-missing)))
- (save-excursion
- (while (<= part-num (string-to-int total))
- (goto-char (point-min))
- (message "Grabbing part %d of %d" part-num (string-to-int total))
- (re-search-forward
- (concat (regexp-quote subject-id) "0*"
- (int-to-string part-num)) nil t)
- (mime/gp:display-article)
- (save-excursion
- (set-buffer article-buf)
- (goto-char (point-min))
- (re-search-forward "^$")
- (let ((delimit (1+ (point))))
- (goto-char (point-min))
- (if (not
- (let ((params (cdr (mime/Content-Type))))
- (and (equal (assoc-value "id" params) id)
- (= (string-to-int (assoc-value "number" params))
- part-num)
- )))
- (progn
- (kill-buffer buffer)
- (error "Couldn't find part %d" part-num)))
- (if (< delimit (point-max))
- (append-to-buffer buffer delimit (point-max))
- )))
- (setq part-num (+ part-num 1))))
- (mime/gp:display-article)
+ (if (or (file-exists-p full-file)
+ (not (y-or-n-p "Merge partials?"))
+ )
+ (mime-article/decode-message/partial beg end cal)
+ (let (cinfo the-id parameters)
+ (setq subject-id (std11-field-body "Subject"))
+ (if (string-match "[0-9\n]+" subject-id)
+ (setq subject-id (substring subject-id 0 (match-beginning 0)))
+ )