#define GETNAME() \
struct componentname *cnp = ap->a_cnp; \
char *name; \
- MALLOC(name, char *, cnp->cn_namelen+1, M_TEMP, M_WAITOK); \
+ name = malloc(cnp->cn_namelen+1, M_TEMP, M_WAITOK); \
memcpy(name, cnp->cn_nameptr, cnp->cn_namelen); \
name[cnp->cn_namelen] = '\0'
-#define DROPNAME() FREE(name, M_TEMP)
+#define DROPNAME() free(name, M_TEMP)
/*
* Here we define compatibility functions/macros for interfaces that
if ((error = vn_lock(fvp, LK_EXCLUSIVE)) != 0)
goto abortit;
- MALLOC(fname, char *, fcnp->cn_namelen + 1, M_TEMP, M_WAITOK);
+ fname = malloc(fcnp->cn_namelen + 1, M_TEMP, M_WAITOK);
memcpy(fname, fcnp->cn_nameptr, fcnp->cn_namelen);
fname[fcnp->cn_namelen] = '\0';
- MALLOC(tname, char *, tcnp->cn_namelen + 1, M_TEMP, M_WAITOK);
+ tname = malloc(tcnp->cn_namelen + 1, M_TEMP, M_WAITOK);
memcpy(tname, tcnp->cn_nameptr, tcnp->cn_namelen);
tname[tcnp->cn_namelen] = '\0';
afs_rename(VTOAFS(fdvp), fname, VTOAFS(tdvp), tname, tcnp->cn_cred);
AFS_GUNLOCK();
- FREE(fname, M_TEMP);
- FREE(tname, M_TEMP);
+ free(fname, M_TEMP);
+ free(tname, M_TEMP);
if (tdvp == tvp)
vrele(tdvp);
else
dp = (const struct dirent *)((const char *)dp + dp->d_reclen))
ncookies++;
- MALLOC(cookies, u_long *, ncookies * sizeof(u_long), M_TEMP,
+ cookies = malloc(ncookies * sizeof(u_long), M_TEMP,
M_WAITOK);
for (dp = dp_start, cookiep = cookies; dp < dp_end;
dp = (const struct dirent *)((const char *)dp + dp->d_reclen)) {