]>
git.saurik.com Git - wxWidgets.git/blob - src/iodbc/config.h
9 * The iODBC driver manager.
11 * Copyright (C) 1995 by Ke Jin <kejin@empress.com>
13 * This library is free software; you can redistribute it and/or
14 * modify it under the terms of the GNU Library General Public
15 * License as published by the Free Software Foundation; either
16 * version 2 of the License, or (at your option) any later version.
18 * This library is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21 * Library General Public License for more details.
23 * You should have received a copy of the GNU Library General Public
24 * License along with this library; if not, write to the Free
25 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
30 #if !defined(WINDOWS) && !defined(WIN32_SYSTEM)
36 #include <sys/types.h>
40 #define MEM_ALLOC(size) (malloc((size_t)(size)))
41 #define MEM_FREE(ptr) {if(ptr) free(ptr);}
43 #define STRCPY(t, s) (strcpy((char*)(t), (char*)(s)))
44 #define STRNCPY(t,s,n) (strncpy((char*)(t), (char*)(s), (size_t)(n)))
45 #define STRCAT(t, s) (strcat((char*)(t), (char*)(s)))
46 #define STRNCAT(t,s,n) (strncat((char*)(t), (char*)(s), (size_t)(n)))
47 #define STREQ(a, b) (strcmp((char*)(a), (char*)(b)) == 0)
48 #define STRLEN(str) ((str)? strlen((char*)(str)):0)
54 typedef signed short SSHOR
;
63 #if defined(WINDOWS) || defined(WIN32_SYSTEM)
68 #define MEM_ALLOC(size) (fmalloc((size_t)(size)))
69 #define MEM_FREE(ptr) ((ptr)? ffree((PTR)(ptr)):0))
70 #define STRCPY(t, s) (fstrcpy((char FAR*)(t), (char FAR*)(s)))
71 #define STRNCPY(t,s,n) (fstrncpy((char FAR*)(t), (char FAR*)(s), (size_t)(n)))
72 #define STRLEN(str) ((str)? fstrlen((char FAR*)(str)):0)
73 #define STREQ(a, b) (fstrcmp((char FAR*)(a), (char FAR*)(b) == 0)
77 #define MEM_ALLOC(size) (farmalloc((unsigned long)(size))
78 #define MEM_FREE(ptr) ((ptr)? farfree((void far*)(ptr)):0)
79 #define STRCPY(t, s) (_fstrcpy((char FAR*)(t), (char FAR*)(s)))
80 #define STRNCPY(t,s,n) (_fstrncpy((char FAR*)(t), (char FAR*)(s), (size_t)(n)))
81 #define STRLEN(str) ((str)? _fstrlen((char FAR*)(str)):0)
82 #define STREQ(a, b) (_fstrcmp((char FAR*)(a), (char FAR*)(b) == 0)
90 #define NULL ((void FAR*)0UL)