add the cleanup checker
[deliverable/binutils-gdb.git] / gdb / remote-fileio.c
index 0e3d533c60f3aa4917feb4688a00e1937288edd0..cc39bdf14add4318d1a7ff29cf347b3c2e80964e 100644 (file)
@@ -1,6 +1,6 @@
 /* Remote File-I/O communications
 
-   Copyright (C) 2003, 2005-2012 Free Software Foundation, Inc.
+   Copyright (C) 2003-2013 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -31,6 +31,7 @@
 #include "event-loop.h"
 #include "target.h"
 #include "filenames.h"
+#include "filestuff.h"
 
 #include <fcntl.h>
 #include <sys/time.h>
@@ -639,7 +640,7 @@ remote_fileio_func_open (char *buf)
     }
 
   remote_fio_no_longjmp = 1;
-  fd = open (pathname, flags, mode);
+  fd = gdb_open_cloexec (pathname, flags, mode);
   if (fd < 0)
     {
       remote_fileio_return_errno (-1);
This page took 0.024937 seconds and 4 git commands to generate.