summaryrefslogtreecommitdiffstats
path: root/src/util/util_lock.c
Commit message (Collapse)AuthorAgeFilesLines
* Make DEBUG macro invocations variadicNikolai Kondrashov2014-02-121-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | Use a script to update DEBUG macro invocations to use it as a variadic macro, supplying format string and its arguments directly, instead of wrapping them in parens. This script was used to update the code: grep -rwl --include '*.[hc]' DEBUG . | while read f; do mv "$f"{,.orig} perl -e \ 'use strict; use File::Slurp; my $text=read_file(\*STDIN); $text=~s#(\bDEBUG\s*\([^(]+)\((.*?)\)\s*\)\s*;#$1$2);#gs; print $text;' < "$f.orig" > "$f" rm "$f.orig" done Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Stephen Gallagher <sgallagh@redhat.com> Reviewed-by: Simo Sorce <simo@redhat.com>
* util_lock.c: sss_br_lock_file accepted invalid parameter valueMichal Zidek2012-11-081-2/+6
| | | | | | Return EINVAL if number of tries is <= 0. Also the parameter retries was renamed to num_tries, so it is more obvious that it also includes the first try.
* util: Added new file util_lock.cMichal Zidek2012-11-061-0/+83