diff options
author | Ted Unangst <tedu@cvs.openbsd.org> | 2015-09-01 13:12:32 +0000 |
---|---|---|
committer | Ted Unangst <tedu@cvs.openbsd.org> | 2015-09-01 13:12:32 +0000 |
commit | 7fffd18f58839f079048dbc1ef5ac199a709b13d (patch) | |
tree | 666bed69f5dc7607a894dd63d798484f39a28a45 /bin/ksh/expand.h | |
parent | e75a4737e7e5686910f3af279fc62c313c1c4cd5 (diff) |
remove casts and null checks before free. from Michael McConville
ok deraadt
Diffstat (limited to 'bin/ksh/expand.h')
-rw-r--r-- | bin/ksh/expand.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/ksh/expand.h b/bin/ksh/expand.h index 7288d4de1a3..5ea1a0ed874 100644 --- a/bin/ksh/expand.h +++ b/bin/ksh/expand.h @@ -1,4 +1,4 @@ -/* $OpenBSD: expand.h,v 1.6 2005/03/30 17:16:37 deraadt Exp $ */ +/* $OpenBSD: expand.h,v 1.7 2015/09/01 13:12:31 tedu Exp $ */ /* * Expanding strings @@ -55,7 +55,7 @@ typedef char * XStringP; #define Xcheck(xs, xp) XcheckN(xs, xp, 1) /* free string */ -#define Xfree(xs, xp) afree((void*) (xs).beg, (xs).areap) +#define Xfree(xs, xp) afree((xs).beg, (xs).areap) /* close, return string */ #define Xclose(xs, xp) (char*) aresize((void*)(xs).beg, \ @@ -104,4 +104,4 @@ typedef struct XPtrV { #define XPclose(x) (void**) aresize((void*)(x).beg, \ sizeofN(void*, XPsize(x)), ATEMP) -#define XPfree(x) afree((void*) (x).beg, ATEMP) +#define XPfree(x) afree((x).beg, ATEMP) |