/*
* Copyright 2000, International Business Machines Corporation and others.
* All Rights Reserved.
- *
+ *
* This software has been released under the terms of the IBM Public
* License. For details, see the LICENSE file in the top-level source
* directory or online at http://www.openafs.org/dl/license10.html
#include <afsconfig.h>
#include "afs/param.h"
-RCSID
- ("$Header$");
#include "afs/stds.h"
#include "afs/sysincludes.h" /* Standard vendor system headers */
#ifdef AFS_SGI62_ENV
#include "h/hashing.h"
#endif
-#if !defined(AFS_HPUX110_ENV) && !defined(AFS_LINUX20_ENV) && !defined(AFS_FBSD_ENV) && !defined(AFS_DARWIN60_ENV)
+#if !defined(AFS_HPUX110_ENV) && !defined(AFS_LINUX20_ENV) && !defined(AFS_FBSD_ENV) && !defined(AFS_DARWIN_ENV)
#include <netinet/in_var.h>
#endif
#endif /* !UKERNEL */
#include "afs/afs_util.h"
#include "afs/unified_afs.h"
-#if defined(AFS_SUN56_ENV)
+#if defined(AFS_SUN5_ENV)
#include <inet/led.h>
#include <inet/common.h>
-#if defined(AFS_SUN58_ENV)
#include <netinet/ip6.h>
-#endif
#include <inet/ip.h>
#endif
et2sys[(UAEDQUOT - ERROR_TABLE_BASE_uae)] = EDQUOT;
et2sys[(UAENOMEDIUM - ERROR_TABLE_BASE_uae)] = ENOMEDIUM;
et2sys[(UAEMEDIUMTYPE - ERROR_TABLE_BASE_uae)] = EMEDIUMTYPE;
+ et2sys[(UAECANCELED - ERROR_TABLE_BASE_uae)] = ECANCELED;
+ et2sys[(UAENOTRECOVERABLE - ERROR_TABLE_BASE_uae)] = ENOTRECOVERABLE;
+ et2sys[(UAENOTSUP - ERROR_TABLE_BASE_uae)] = ENOTSUP;
+ et2sys[(UAEOTHER - ERROR_TABLE_BASE_uae)] = EOTHER;
+ et2sys[(UAEOWNERDEAD - ERROR_TABLE_BASE_uae)] = EOWNERDEAD;
+ et2sys[(UAEPROCLIM - ERROR_TABLE_BASE_uae)] = EPROCLIM;
+ et2sys[(UAEDISCON - ERROR_TABLE_BASE_uae)] = EDISCON;
}
afs_int32
}
void
-afs_CopyError(register struct vrequest *afrom, register struct vrequest *ato)
+afs_CopyError(struct vrequest *afrom, struct vrequest *ato)
{
+ int i = 0;
AFS_STATCNT(afs_CopyError);
if (!afrom->initd)
return;
afs_FinalizeReq(ato);
+ while (i < AFS_MAXHOSTS) {
+ ato->skipserver[i] = afrom->skipserver[i];
+ ato->lasterror[i] = afrom->lasterror[i];
+ i++;
+ }
+ if (afrom->tokenError)
+ ato->tokenError = afrom->tokenError;
+ if (afrom->idleError)
+ ato->idleError = afrom->idleError;
if (afrom->accessError)
ato->accessError = 1;
if (afrom->volumeError)
}
void
-afs_FinalizeReq(register struct vrequest *areq)
+afs_FinalizeReq(struct vrequest *areq)
{
+ int i = 0;
AFS_STATCNT(afs_FinalizeReq);
if (areq->initd)
return;
+ while (i < AFS_MAXHOSTS) {
+ areq->skipserver[i] = 0;
+ areq->lasterror[i] = 0;
+ i++;
+ }
areq->busyCount = 0;
+ areq->idleError = 0;
+ areq->tokenError = 0;
areq->accessError = 0;
areq->volumeError = 0;
areq->networkError = 0;
if (areq->volumeError == VOLBUSY)
return EWOULDBLOCK;
if (acode == VNOVNODE)
- return ENOENT;
+ return EIO;
if (acode == VDISKFULL)
return ENOSPC;
if (acode == VOVERQUOTA)
ENOSPC
#endif
;
+ /* Some fileservers kill overly-idle calls with VNOSERVICE. */
+ if (acode == VNOSERVICE)
+ return ETIMEDOUT;
return acode;