on Darwin, use NSCParameterAssert() instead of assert().

This commit is contained in:
Charles Kerr
2007-11-09 19:50:40 +00:00
parent 2c2d3aaded
commit 67b719c2de
24 changed files with 11 additions and 23 deletions

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <ctype.h> /* isdigit, isprint */
#include <stdarg.h>
#include <stdio.h>

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <string.h>
#include "transmission.h"

View File

@@ -11,7 +11,6 @@
*/
#include <sys/types.h> /* for event.h, as well as netinet/in.h on some platforms */
#include <assert.h>
#include <inttypes.h> /* uint8_t */
#include <string.h> /* memcpy */
#include <stdarg.h>

View File

@@ -41,7 +41,6 @@
* so the resume file will not be read).
**********************************************************************/
#include <assert.h>
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <errno.h>
#include <inttypes.h>
#include <stdio.h>

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include <errno.h>
#include <inttypes.h>
#include <limits.h> /* UCHAR_MAX */

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include <stdlib.h>
#include <string.h>

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <errno.h>
#include <limits.h>
#include <stdio.h>

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include <errno.h>
#include <math.h>
#include <stdio.h> /* FILE, snprintf, stderr */

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <errno.h>
#include <stdlib.h>
#include <string.h>

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include <string.h>
#include <stdio.h>
#include <unistd.h>

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include <string.h> /* memcpy, memcmp */
#include <stdlib.h> /* qsort */
#include <stdio.h> /* printf */

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include <ctype.h>
#include <errno.h>
#include <stdio.h>

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include <stdlib.h>
#include <string.h> /* memmove */

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include "list.h"
#include "publish.h"
#include "utils.h"

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include <ctype.h> /* isalnum */
#include <stdio.h> /* snprintf */
#include <stdlib.h>

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

View File

@@ -10,7 +10,6 @@
* $Id$
*/
#include <assert.h>
#include <errno.h>
#include <stdlib.h>
#include <string.h>

View File

@@ -22,7 +22,6 @@
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#include <assert.h>
#include <ctype.h>
#include <errno.h>
#include <stdarg.h>

View File

@@ -90,6 +90,17 @@ void tr_wait( uint64_t delay_milliseconds );
****
***/
#ifdef SYS_DARWIN
#include <Foundation/Foundation.h>
#define assert(A) NSCParameterAssert(A)
#else
#include <assert.h>
#endif
/***
****
***/
#define tr_new(struct_type, n_structs) \
((struct_type *) tr_malloc (((size_t) sizeof (struct_type)) * ((size_t) (n_structs))))
#define tr_new0(struct_type, n_structs) \