]> git.proxmox.com Git - mirror_frr.git/blame - tools/coccinelle/frr_with_mutex.cocci
Merge pull request #8593 from idryzhov/cmd-ambiguous
[mirror_frr.git] / tools / coccinelle / frr_with_mutex.cocci
CommitLineData
00dffa8c
DL
1@@
2expression E;
3iterator name frr_with_mutex;
4@@
5
6- pthread_mutex_lock(E);
7+ frr_with_mutex(E) {
8- {
9 ...
10- }
11- pthread_mutex_unlock(E);
12+ }
13
14
15@@
16expression E;
17@@
18
19- pthread_mutex_lock(E);
20+ frr_with_mutex(E) {
21 ...
22- pthread_mutex_unlock(E);
23+ }