changeset 85:6e3246ae87fd

added comment about why the rename() call is safe
author mortenp
date Wed, 19 May 2004 03:02:20 +1000
parents 620475b58755
children e7813152c0f0
files src/mlmmj-send.c
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/mlmmj-send.c	Wed May 19 01:25:36 2004 +1000
+++ b/src/mlmmj-send.c	Wed May 19 03:02:20 2004 +1000
@@ -433,6 +433,11 @@
 	}
 	
 	if(listctrl[0] != '1' && listctrl[0] != '2') {
+		/* It is safe to rename() the mail file at this point, because
+		   the child processes (who might still be running) inhirit a
+		   handle to the open file, so they don't care if it is moved
+		   or deleted. */
+
 		/* The mail now goes to the archive */
 		rename(mailfilename, archivefilename);