]> git.ipfire.org Git - thirdparty/systemd.git/blame - coccinelle/iovec-make.cocci
firstboot: Check if the given shell exists
[thirdparty/systemd.git] / coccinelle / iovec-make.cocci
CommitLineData
5cfa2c3d
LP
1@@
2expression x, y, p, l;
3@@
4- x[y].iov_base = p;
5- x[y].iov_len = l;
6- y++;
7+ x[y++] = IOVEC_MAKE(p, l);
8@@
9expression x, p, l;
10@@
11- x.iov_base = p;
12- x.iov_len = l;
13+ x = IOVEC_MAKE(p, l);
14@@
15expression x, p, l;
16@@
17- x->iov_base = p;
18- x->iov_len = l;
19+ *x = IOVEC_MAKE(p, l);
20@@
21expression s;
22@@
23- IOVEC_MAKE(s, strlen(s));
24+ IOVEC_MAKE_STRING(s);
cb310866
LP
25@@
26expression x, y, z;
27@@
28- x = (struct iovec) { .iov_base = y, .iov_len = z };
29+ x = IOVEC_MAKE(y, z);