summaryrefslogtreecommitdiff
path: root/ace/Malloc.h
diff options
context:
space:
mode:
authornanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-11-29 22:38:25 +0000
committernanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-11-29 22:38:25 +0000
commita4c928de745c18832ac184cdebc051a39945d7d4 (patch)
treee430f07fa61fd638ecbf8c90cc233d0c6baf94dd /ace/Malloc.h
parentc95e8fe99008e8f4bbb5c677e54fcdfd61911f5d (diff)
downloadATCD-a4c928de745c18832ac184cdebc051a39945d7d4.tar.gz
ChangeLogTag:Mon Nov 29 16:36:06 1999 Nanbor Wang <nanbor@cs.wustl.edu>
Diffstat (limited to 'ace/Malloc.h')
-rw-r--r--ace/Malloc.h13
1 files changed, 4 insertions, 9 deletions
diff --git a/ace/Malloc.h b/ace/Malloc.h
index 4d089b2832a..9d00418f5b6 100644
--- a/ace/Malloc.h
+++ b/ace/Malloc.h
@@ -69,13 +69,8 @@ struct ACE_Export ACE_Malloc_Stats
// multiple, like 8-byte data alignment, etc. The allocated area's
// padding to your selected size is done with an added array of long[]
// and your compiler will decide how to align things in memory.
-//
-// If you want to use this feature, define ACE_MALLOC_PADDING in your
-// config.h file and use a signed integer number of bytes you want, e.g.:
-//
-// #define ACE_MALLOC_PADDING ((int) 4096)
-#define ACE_MALLOC_PADDING 1
+#define ACE_MALLOC_PADDING 16
#endif /* ACE_MALLOC_PADDING */
#if defined (ACE_HAS_POSITION_INDEPENDENT_MALLOC)
@@ -104,8 +99,8 @@ public:
// Size of this header control block.
#if (ACE_MALLOC_PADDING > 1)
-#define ACE_MALLOC_PADDING_SIZE ((ACE_MALLOC_PADDING - \
- (sizeof (ACE_MALLOC_HEADER_PTR) + sizeof (size_t)) / sizeof (long)))
+#define ACE_MALLOC_PADDING_SIZE ((int) (ACE_MALLOC_PADDING - \
+ (sizeof (ACE_MALLOC_HEADER_PTR) + sizeof (size_t))) / (int) sizeof (long))
long padding_[ACE_MALLOC_PADDING_SIZE < 1 ? 1 : ACE_MALLOC_PADDING_SIZE];
#endif /* ACE_MALLOC_PADDING > 0 */
@@ -199,7 +194,7 @@ public:
+ sizeof (ACE_Malloc_Stats)))
#else
#define ACE_CONTROL_BLOCK_SIZE ((int)(sizeof (ACE_NAME_NODE_PTR) \
- + sizeof (ACE_MALLOC_HEADER_PTR *) \
+ + sizeof (ACE_MALLOC_HEADER_PTR) \
+ MAXNAMELEN))
#endif /* ACE_HAS_MALLOC_STATS */