about summary refs log tree commit diff
path: root/gmon
diff options
context:
space:
mode:
Diffstat (limited to 'gmon')
-rw-r--r--gmon/gmon.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gmon/gmon.c b/gmon/gmon.c
index 407993d571..dd4ee3a79d 100644
--- a/gmon/gmon.c
+++ b/gmon/gmon.c
@@ -114,7 +114,7 @@ __monstartup (lowpc, highpc)
   p->lowpc = ROUNDDOWN(lowpc, HISTFRACTION * sizeof(HISTCOUNTER));
   p->highpc = ROUNDUP(highpc, HISTFRACTION * sizeof(HISTCOUNTER));
   p->textsize = p->highpc - p->lowpc;
-  p->kcountsize = p->textsize / HISTFRACTION;
+  p->kcountsize = ROUNDUP(p->textsize / HISTFRACTION, sizeof(*p->froms));
   p->hashfraction = HASHFRACTION;
   p->log_hashfraction = -1;
   /* The following test must be kept in sync with the corresponding