X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=utils%2Fmount%2Ferror.c;h=f8fc13fea3d794048e73cd05a2eaa9d2d0bd27c3;hb=da56ddf07ce41bd324c5c38db7d9ac03f4887258;hp=4cc9e0949e3645dbbd6b17c077161e3adb5ab2f5;hpb=906f0b27730b0506a24ed43029983b4d6819dd12;p=nfs-utils.git diff --git a/utils/mount/error.c b/utils/mount/error.c index 4cc9e09..f8fc13f 100644 --- a/utils/mount/error.c +++ b/utils/mount/error.c @@ -16,8 +16,8 @@ * * You should have received a copy of the GNU General Public * License along with this program; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 021110-1307, USA. + * Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 0211-1301 USA * * To Do: * + Proper support for internationalization @@ -70,9 +70,15 @@ static int rpc_strerror(int spos) pos = snprintf(tmp, (erreob - tmp), _("System Error: %s"), strerror(cf_errno)); - else - pos = snprintf(tmp, (erreob - tmp), - _("RPC Error:%s"), estr); + else { + if (cf_errno) + pos = snprintf(tmp, (erreob - tmp), + _("RPC Error:%s; errno = %s"), + estr, strerror(cf_errno)); + else + pos = snprintf(tmp, (erreob - tmp), + _("RPC Error:%s"), estr); + } } return pos; } @@ -219,7 +225,7 @@ void mount_error(const char *spec, const char *mount_point, int error) case ENOENT: if (spec) nfs_error(_("%s: mounting %s failed, " - "reason given by server:\n %s"), + "reason given by server: %s"), progname, spec, strerror(error)); else nfs_error(_("%s: mount point %s does not exist"),