From 9ad601edd66a5aabdbf75effe2a05ace290dbe2a Mon Sep 17 00:00:00 2001 From: "David G. Holm" Date: Thu, 14 Jun 2001 18:06:27 +0000 Subject: [PATCH] See ChangeLog entry 2001-06-14 14:00 UTC-0400 David G. Holm --- harbour/ChangeLog | 6 ++++++ harbour/source/rdd/dbfcdx/dbfcdx1.h | 16 ++++++++-------- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 2913ec5900..15de48c574 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -1,3 +1,9 @@ +2001-06-14 14:00 UTC-0400 David G. Holm + + * source/rdd/dbfcdx/dbfcdx1.h + * Added #pragma pack(1) and #pragma pack() for C++ builds to eliminate + the exception c0000005 that resulted from incorrect structure layouts. + 2001-06-14 13:15 UTC-0400 David G. Holm * include/hbapierr.h diff --git a/harbour/source/rdd/dbfcdx/dbfcdx1.h b/harbour/source/rdd/dbfcdx/dbfcdx1.h index c3c3b427a3..7cdb84ae81 100644 --- a/harbour/source/rdd/dbfcdx/dbfcdx1.h +++ b/harbour/source/rdd/dbfcdx/dbfcdx1.h @@ -63,12 +63,12 @@ #if (__BORLANDC__ > 1040) /* Use this only above Borland C++ 3.1 */ #pragma option -a1 /* byte alignment */ -#endif -#if defined(__GNUC__) +#elif defined(__GNUC__) #pragma pack(1) -#endif -#if defined(__WATCOMC__) +#elif defined(__WATCOMC__) #pragma pack(push, 1); +#elif defined(__cplusplus) + #pragma pack(1) #endif typedef struct @@ -101,12 +101,12 @@ typedef struct _CDXDATA } CDXDATA; #if (__BORLANDC__ > 1040) /* Use this only above Borland C++ 3.1 */ #pragma option -a /* default alignment */ -#endif -#if defined(__GNUC__) +#elif defined(__GNUC__) #pragma pack() -#endif -#if defined(__WATCOMC__) +#elif defined(__WATCOMC__) #pragma pack(pop); +#elif defined(__cplusplus) + #pragma pack() #endif typedef CDXDATA * LPCDXDATA;