gwr commented on this pull request.
> +{
+ nvlist_t *nvl = NULL;
+ int err;
+
+ err = nvlist_alloc(&nvl, NV_UNIQUE_NAME, 0);
+ if (err != 0)
+ return (err);
+
+ (void) nvlist_add_boolean_value(nvl, A_READONLY, 1);
+
+ if (fname == NULL) {
+ err = fsetattr(fildes, XATTR_VIEW_READWRITE, nvl);
+ } else {
+ err = setattrat(fildes, XATTR_VIEW_READWRITE, fname, nvl);
+ }
+ if (err < 0) {
Oh, well the code was "borrowed" from something else where fname could be
passed in.
I could go either way (minimize this code, vs leave it more general).
Your thoughts on which way is better?
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openzfs/openzfs/pull/392#discussion_r120876944
------------------------------------------
openzfs-developer
Archives:
https://openzfs.topicbox.com/groups/developer/discussions/Tb6ca17b06450145d-Mbb6ceb920ffe318bfd3f6bd2
Powered by Topicbox: https://topicbox.com