From 37f8ad0f3e64c23cd32c8c58636510f7964f1891 Mon Sep 17 00:00:00 2001 From: Nikias Bassen Date: Sun, 19 Jul 2009 20:07:21 +0200 Subject: New type afc_lock_op_t with allowed lock operations for afc_lock_file. Only non-blocking locks are supported via AFC. Signed-off-by: Martin Szulecki --- dev/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'dev') diff --git a/dev/main.c b/dev/main.c index cf7dbaa..33ebc2d 100644 --- a/dev/main.c +++ b/dev/main.c @@ -128,7 +128,7 @@ int main(int argc, char *argv[]) afc_open_file(afc, "/com.apple.itunes.lock_sync", AFC_FOPEN_RW, &lockfile); if (lockfile) { printf("locking file\n"); - afc_lock_file(afc, lockfile, 2 | 4); + afc_lock_file(afc, lockfile, AFC_LOCK_EX); perform_notification(phone, client, NP_SYNC_DID_START); } @@ -227,7 +227,7 @@ int main(int argc, char *argv[]) //perform_notification(phone, control, NP_SYNC_DID_FINISH); printf("XXX unlocking file\n"); - afc_lock_file(afc, lockfile, 8 | 4); + afc_lock_file(afc, lockfile, AFC_LOCK_UN); printf("XXX closing file\n"); afc_close_file(afc, lockfile); -- cgit v1.1-32-gdbae