Author: wlux
Date: Mon Feb 16 18:27:57 2015
New Revision: 38344
URL: http://svn.gna.org/viewcvs/gnustep?rev=38344&view=rev
Log:
Fix leak of open file descriptor in NSData -writeToFile:atomically: on
systems where mkstemp is defined.
Modified:
libs/base/trunk/ChangeLog
libs/base/trunk/Source/NSData.m
Modified: libs/base/trunk/ChangeLog
URL:
http://svn.gna.org/viewcvs/gnustep/libs/base/trunk/ChangeLog?rev=38344&r1=38343&r2=38344&view=diff
==============================================================================
--- libs/base/trunk/ChangeLog (original)
+++ libs/base/trunk/ChangeLog Mon Feb 16 18:27:57 2015
@@ -1,3 +1,8 @@
+2015-02-16 Wolfgang Lux <[email protected]>
+
+ * Source/NSData.m (writeToFile:options:error:): Fix leak of open
+ file descriptor on systems where mkstemp is defined.
+
2015-02-15 Richard Frith-Macdonald <[email protected]>
* config/objc-sys-dynamic.m4: Check for windows before anything else
Modified: libs/base/trunk/Source/NSData.m
URL:
http://svn.gna.org/viewcvs/gnustep/libs/base/trunk/Source/NSData.m?rev=38344&r1=38343&r2=38344&view=diff
==============================================================================
--- libs/base/trunk/Source/NSData.m (original)
+++ libs/base/trunk/Source/NSData.m Mon Feb 16 18:27:57 2015
@@ -1583,8 +1583,8 @@
strncpy(thePath, theRealPath, sizeof(thePath) - 1);
thePath[sizeof(thePath) - 1] = '\0';
}
+ theFile = fopen(thePath, "wb");
# endif
- theFile = fopen(thePath, "wb");
if (theFile == 0)
{
_______________________________________________
Gnustep-cvs mailing list
[email protected]
https://mail.gna.org/listinfo/gnustep-cvs