summaryrefslogtreecommitdiff
path: root/fs/omfs
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2021-05-12 14:51:03 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2021-05-18 20:14:53 -0400
commitad08ae586586ea9e2c0228a3d5a083500ea54202 (patch)
tree913a993f6105312326fac24cbb6f909c80ecb899 /fs/omfs
parent95b55c42f65af3fb9e2dceaf4d8dde522c0472d3 (diff)
d_path: introduce struct prepend_buffer
We've a lot of places where we have pairs of form (pointer to end of buffer, amount of space left in front of that). These sit in pairs of variables located next to each other and usually passed by reference. Turn those into instances of new type (struct prepend_buffer) and pass reference to the pair instead of pairs of references to its fields. Declared and initialized by DECLARE_BUFFER(name, buf, buflen). extract_string(prepend_buffer) returns the buffer contents if no overflow has happened, ERR_PTR(ENAMETOOLONG) otherwise. All places where we used to have that boilerplate converted to use of that helper. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/omfs')
0 files changed, 0 insertions, 0 deletions