mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-26 23:28:14 +03:00
Csync: Add hook for checking if a file is in use already
This commit is contained in:
parent
642c16b09b
commit
b39359c929
2 changed files with 9 additions and 0 deletions
|
@ -180,3 +180,10 @@ csync_vio_file_stat_t *csync_vio_convert_file_stat(csync_file_stat_t *st) {
|
|||
|
||||
return vfs;
|
||||
}
|
||||
|
||||
bool (*csync_file_locked_or_open_ext) (const char*) = 0; // filled in by library user
|
||||
bool csync_file_locked_or_open( const char *file) {
|
||||
if (!csync_file_locked_or_open_ext)
|
||||
return false;
|
||||
return csync_file_locked_or_open_ext(file);
|
||||
}
|
||||
|
|
|
@ -35,4 +35,6 @@ void csync_win32_set_file_hidden( const char *file, bool hidden );
|
|||
/* Convert a csync_file_stat_t to csync_vio_file_stat_t */
|
||||
csync_vio_file_stat_t *csync_vio_convert_file_stat(csync_file_stat_t *st);
|
||||
|
||||
bool csync_file_locked_or_open( const char *file);
|
||||
|
||||
#endif /* _CSYNC_UTIL_H */
|
||||
|
|
Loading…
Reference in a new issue