You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by jc...@apache.org on 2011/04/05 00:28:57 UTC
svn commit: r1088808 -
/subversion/branches/1.6.x-issue3719/subversion/libsvn_subr/io.c
Author: jcorvel
Date: Mon Apr 4 22:28:57 2011
New Revision: 1088808
URL: http://svn.apache.org/viewvc?rev=1088808&view=rev
Log:
On the 1.6.x-issue3719 branch:
Fix compilation on Windows.
* subversion/libsvn_subr/io.c
(): Include private/svn_atomic.h. Add missing declaration of
tempname_counter (ifdef WIN32), which was probably lost during backporting.
Modified:
subversion/branches/1.6.x-issue3719/subversion/libsvn_subr/io.c
Modified: subversion/branches/1.6.x-issue3719/subversion/libsvn_subr/io.c
URL: http://svn.apache.org/viewvc/subversion/branches/1.6.x-issue3719/subversion/libsvn_subr/io.c?rev=1088808&r1=1088807&r2=1088808&view=diff
==============================================================================
--- subversion/branches/1.6.x-issue3719/subversion/libsvn_subr/io.c (original)
+++ subversion/branches/1.6.x-issue3719/subversion/libsvn_subr/io.c Mon Apr 4 22:28:57 2011
@@ -53,6 +53,8 @@
#include "svn_dirent_uri.h"
#include "svn_private_config.h"
+#include "private/svn_atomic.h"
+
#define SVN_SLEEP_ENV_VAR "SVN_I_LOVE_CORRUPTED_WORKING_COPIES_SO_DISABLE_SLEEP_FOR_TIMESTAMPS"
/*
@@ -459,6 +461,13 @@ svn_io_open_uniquely_named(apr_file_t **
svn_path_local_style(path, scratch_pool));
}
+#ifdef WIN32
+/* Counter value of file_mktemp request (used in a threadsafe way), to make
+ sure that a single process normally never generates the same tempname
+ twice */
+static volatile apr_uint32_t tempname_counter = 0;
+#endif
+
/* Creates a new temporary file in DIRECTORY with apr flags FLAGS.
Set *NEW_FILE to the file handle and *NEW_FILE_NAME to its name.
Perform temporary allocations in SCRATCH_POOL and the result in