-
-/*
- * refile.c -- move or link message(s) from a source folder
+/* refile.c -- move or link message(s) from a source folder
* -- into one or more destination folders
*
* This code is Copyright (c) 2002, by the authors of nmh. See the
*/
for (msgnum = mp->lowsel; msgnum <= mp->hghsel; msgnum++) {
if (is_selected (mp, msgnum)) {
- cp = getcpy (m_name (msgnum));
+ cp = mh_xstrdup(m_name (msgnum));
if (m_file (mp, cp, retainseqs ? msgnum : 0, folders, foldp,
preserve, !linkf))
done (1);
/*
- * Set the Previous-Sequence and then sychronize the
+ * Set the Previous-Sequence and then synchronize the
* sequence file, for each destination folder.
*/
* therefore won't be assigned to be the current message.
*/
if ((msgnum = folder_addmsg (&fp->f_mp, msgfile,
- mp == fp->f_mp ? 0 : 1,
+ mp != fp->f_mp,
0, preserve, nfolders == 1 && refile,
maildir)) == -1)
return 1;
assert ((int) seqnum == seq_getnum (oldmp, *seq));
if (in_sequence (oldmp, seqnum, oldmsgnum)) {
seq_addmsg (newmp, *seq, newmsgnum,
- is_seq_private (oldmp, seqnum) ? 0 : 1, 0);
+ !is_seq_private (oldmp, seqnum), 0);
}
}
}