|
@@ -275,6 +275,7 @@ int _starpu_frdunlock(FILE *file)
|
|
# ifndef _LK_UNLCK
|
|
# ifndef _LK_UNLCK
|
|
# define _LK_UNLCK _LK_UNLOCK
|
|
# define _LK_UNLCK _LK_UNLOCK
|
|
# endif
|
|
# endif
|
|
|
|
+ ret = _lseek(fileno(file), 0, SEEK_SET);
|
|
ret = _locking(fileno(file), _LK_UNLCK, 10);
|
|
ret = _locking(fileno(file), _LK_UNLCK, 10);
|
|
#else
|
|
#else
|
|
struct flock lock =
|
|
struct flock lock =
|
|
@@ -294,6 +295,7 @@ int _starpu_fwrlock(FILE *file)
|
|
{
|
|
{
|
|
int ret;
|
|
int ret;
|
|
#if defined(_WIN32) && !defined(__CYGWIN__)
|
|
#if defined(_WIN32) && !defined(__CYGWIN__)
|
|
|
|
+ ret = _lseek(fileno(file), 0, SEEK_SET);
|
|
do
|
|
do
|
|
{
|
|
{
|
|
ret = _locking(fileno(file), _LK_LOCK, 10);
|
|
ret = _locking(fileno(file), _LK_LOCK, 10);
|