[Asterisk-cvs] asterisk file.c,1.51,1.51.2.1

russell at lists.digium.com russell at lists.digium.com
Sun Feb 6 21:53:05 CST 2005


Update of /usr/cvsroot/asterisk
In directory mongoose.digium.com:/tmp/cvs-serv8697

Modified Files:
      Tag: v1-0
	file.c 
Log Message:
Fix wav append mode (bug #3498)


Index: file.c
===================================================================
RCS file: /usr/cvsroot/asterisk/file.c,v
retrieving revision 1.51
retrieving revision 1.51.2.1
diff -u -d -r1.51 -r1.51.2.1
--- file.c	20 Sep 2004 23:15:49 -0000	1.51
+++ file.c	7 Feb 2005 03:53:36 -0000	1.51.2.1
@@ -844,8 +844,12 @@
 		return NULL;
 	}
 	/* set the O_TRUNC flag if and only if there is no O_APPEND specified */
-	if (!(flags & O_APPEND)) 
+	if (flags & O_APPEND){ 
+		/* We really can't use O_APPEND as it will break WAV header updates */
+		flags &= ~O_APPEND;
+	}else{
 		myflags = O_TRUNC;
+	}
 	
 	myflags |= O_WRONLY | O_CREAT;
 




More information about the svn-commits mailing list