X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=ncurses%2Fbuild.priv.h;h=84e4c52a220a314fc9d85bab4fabeca410f35e7e;hp=be00d73ea4309ac8ee6747e76f065982e1db320a;hb=b025434573f466efe27862656a6a9d41dd2bd609;hpb=a2ea66477b08cf07200cf7c319447d61d1360d85 diff --git a/ncurses/build.priv.h b/ncurses/build.priv.h index be00d73e..84e4c52a 100644 --- a/ncurses/build.priv.h +++ b/ncurses/build.priv.h @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 2010 Free Software Foundation, Inc. * + * Copyright (c) 2010-2012,2019 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -30,9 +30,8 @@ * Author: Thomas E. Dickey 2010 * ****************************************************************************/ - /* - * $Id: build.priv.h,v 1.6 2010/05/22 20:30:35 tom Exp $ + * $Id: build.priv.h,v 1.10 2019/05/11 14:14:00 tom Exp $ * * build.priv.h * @@ -78,11 +77,12 @@ extern "C" { #define EXIT_FAILURE 1 #endif -#define FreeAndNull(p) free(p); p = 0 +#define FreeAndNull(p) do { free(p); p = 0; } while (0) #define UChar(c) ((unsigned char)(c)) #define SIZEOF(v) (sizeof(v) / sizeof(v[0])) #include +#include /* declare these, to avoid needing term.h */ #if BROKEN_LINKER || USE_REENTRANT