mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
Add a flag parameter to dotlock_create.
This allows us to extend this function in the future.
This commit is contained in:
parent
567a31c2a0
commit
ed8e267859
15 changed files with 37 additions and 24 deletions
|
@ -90,7 +90,7 @@ lock_and_unlock (const char *fname)
|
|||
{
|
||||
dotlock_t h;
|
||||
|
||||
h = dotlock_create (fname);
|
||||
h = dotlock_create (fname, 0);
|
||||
if (!h)
|
||||
die ("error creating lock file for `%s': %s", fname, strerror (errno));
|
||||
inf ("lock created");
|
||||
|
@ -129,7 +129,7 @@ main (int argc, char **argv)
|
|||
sigaction (SIGINT, &nact, NULL);
|
||||
}
|
||||
|
||||
dotlock_create (NULL); /* Initialize (optional). */
|
||||
dotlock_create (NULL, 0); /* Initialize (optional). */
|
||||
|
||||
lock_and_unlock (fname);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue