summaryrefslogtreecommitdiff
path: root/src/test/examples/testlo2.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/examples/testlo2.c')
-rw-r--r--src/test/examples/testlo2.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/test/examples/testlo2.c b/src/test/examples/testlo2.c
index f23ded8458..31607ba0f1 100644
--- a/src/test/examples/testlo2.c
+++ b/src/test/examples/testlo2.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/test/examples/Attic/testlo2.c,v 1.6 1997/09/25 16:35:52 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/test/examples/Attic/testlo2.c,v 1.7 1998/05/12 21:44:08 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -164,7 +164,7 @@ exportFile(PGconn *conn, Oid lobjId, char *filename)
/*
* open the file to be written to
*/
- fd = open(filename, O_CREAT | O_WRONLY, 0666);
+ fd = open(filename, O_CREAT | O_WRONLY | O_TRUNC, 0666);
if (fd < 0)
{ /* error */
fprintf(stderr, "can't open unix file\"%s\"",