mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-27 09:30:13 +03:00
owncloud: memclear a buf and remove not needed win32 code.
This commit is contained in:
parent
ad453115b4
commit
fd9a380fc9
1 changed files with 1 additions and 9 deletions
|
@ -712,6 +712,7 @@ static csync_vio_method_handle_t *owncloud_open(const char *durl,
|
|||
|
||||
struct transfer_context *writeCtx = NULL;
|
||||
csync_stat_t statBuf;
|
||||
memset( getUrl, '\0', PATH_MAX );
|
||||
|
||||
(void) mode; /* unused on webdav server */
|
||||
DEBUG_WEBDAV(( "=> open called for %s\n", durl ));
|
||||
|
@ -779,15 +780,6 @@ static csync_vio_method_handle_t *owncloud_open(const char *durl,
|
|||
}
|
||||
#else
|
||||
writeCtx->tmpFileName = c_strdup( "/tmp/csync.XXXXXX" );
|
||||
#ifdef _WIN32
|
||||
if( c_tmpname( writeCtx->tmpFileName ) == 0 ) {
|
||||
_fmode = _O_BINARY;
|
||||
|
||||
writeCtx->fd = open( writeCtx->tmpFileName, O_RDWR | O_CREAT | O_EXCL, 0600 );
|
||||
} else {
|
||||
writeCtx->fd = -1;
|
||||
}
|
||||
#else
|
||||
writeCtx->fd = mkstemp( writeCtx->tmpFileName );
|
||||
#endif
|
||||
DEBUG_WEBDAV(("opening temp directory %s\n", writeCtx->tmpFileName ));
|
||||
|
|
Loading…
Reference in a new issue