summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/afs/src/lwp/lwp_asm.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/usr.sbin/afs/src/lwp/lwp_asm.c b/usr.sbin/afs/src/lwp/lwp_asm.c
index 9cf778366f2..48a5cf4db51 100644
--- a/usr.sbin/afs/src/lwp/lwp_asm.c
+++ b/usr.sbin/afs/src/lwp/lwp_asm.c
@@ -465,11 +465,13 @@ LWP_CreateProcess(void (*ep)(), int stacksize, int priority,
#else /* !AFS_AIX32_ENV */
if ((stackptr = (char *) lwp_stackmalloc(stacksize)) == NULL) {
Set_LWP_RC();
+ free(temp);
return LWP_ENOMEM;
}
#endif /* AFS_AIX32_ENV */
if (priority < 0 || priority >= MAX_PRIORITIES) {
Set_LWP_RC();
+ free(temp);
return LWP_EBADPRI;
}
Initialize_Stack(stackptr, stacksize);