Project

General

Profile

Bug #6280

libzfs: unshare_one() could fail with EZFS_SHARENFSFAILED

Added by Marcel Telka almost 4 years ago. Updated almost 4 years ago.

Status:
Closed
Priority:
Low
Assignee:
Category:
lib - userland libraries
Start date:
2015-10-02
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
needs-triage

Description

The unshare_one() in libzfs could fail with EZFS_SHARENFSFAILED at line 834 here:

831    /* make sure libshare initialized */
832    if ((err = zfs_init_libshare(hdl, SA_INIT_SHARE_API)) != SA_OK) {
833        free(mntpt);    /* don't need the copy anymore */
834        return (zfs_error_fmt(hdl, EZFS_SHARENFSFAILED,
835            dgettext(TEXT_DOMAIN, "cannot unshare '%s': %s"),
836            name, _sa_errorstr(err)));
837    }

The correct error should be EZFS_UNSHARENFSFAILED instead.


Related issues

Related to illumos gate - Bug #8331: zfs_unshare returns wrong error code for smb unshare failureClosed2017-06-05

Actions

History

#1

Updated by Marcel Telka almost 4 years ago

  • Status changed from In Progress to Pending RTI
#2

Updated by Electric Monk almost 4 years ago

  • Status changed from Pending RTI to Closed
  • % Done changed from 0 to 100

git commit d1672efb6feac57c42788e27f739dfa3c4f3baf7

commit  d1672efb6feac57c42788e27f739dfa3c4f3baf7
Author: Marcel Telka <marcel.telka@nexenta.com>
Date:   2015-10-03T22:04:55.000Z

    6280 libzfs: unshare_one() could fail with EZFS_SHARENFSFAILED
    Reviewed by: Toomas Soome <tsoome@me.com>
    Reviewed by: Dan McDonald <danmcd@omniti.com>
    Reviewed by: Matthew Ahrens <mahrens@delphix.com>
    Approved by: Gordon Ross <gwr@nexenta.com>

#3

Updated by Marcel Telka over 2 years ago

  • Related to Bug #8331: zfs_unshare returns wrong error code for smb unshare failure added

Also available in: Atom PDF