summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Evans <je@fb.com>2014-01-17 02:04:30 (GMT)
committerJason Evans <je@fb.com>2014-01-17 02:04:30 (GMT)
commiteefdd02e70ec1b9cf11920fcff585835dcbd766b (patch)
tree3be4e2cd883362089ccbca6b70dba1399f4c552e
parentf234dc51b9740242d8ba69307db7c5a1312f5a03 (diff)
downloadjemalloc-eefdd02e70ec1b9cf11920fcff585835dcbd766b.zip
jemalloc-eefdd02e70ec1b9cf11920fcff585835dcbd766b.tar.gz
jemalloc-eefdd02e70ec1b9cf11920fcff585835dcbd766b.tar.bz2
Fix a variable prototype/definition mismatch.
-rw-r--r--include/jemalloc/internal/prof.h7
-rw-r--r--src/prof.c3
2 files changed, 7 insertions, 3 deletions
diff --git a/include/jemalloc/internal/prof.h b/include/jemalloc/internal/prof.h
index 4a8073f..566739b 100644
--- a/include/jemalloc/internal/prof.h
+++ b/include/jemalloc/internal/prof.h
@@ -200,7 +200,12 @@ extern bool opt_prof_gdump; /* High-water memory dumping. */
extern bool opt_prof_final; /* Final profile dumping. */
extern bool opt_prof_leak; /* Dump leak summary at exit. */
extern bool opt_prof_accum; /* Report cumulative bytes. */
-extern char opt_prof_prefix[PATH_MAX + 1];
+extern char opt_prof_prefix[
+ /* Minimize memory bloat for non-prof builds. */
+#ifdef JEMALLOC_PROF
+ PATH_MAX +
+#endif
+ 1];
/*
* Profile dump interval, measured in bytes allocated. Each arena triggers a
diff --git a/src/prof.c b/src/prof.c
index 45cb67f..0d65212 100644
--- a/src/prof.c
+++ b/src/prof.c
@@ -29,8 +29,7 @@ char opt_prof_prefix[
#ifdef JEMALLOC_PROF
PATH_MAX +
#endif
- 1
-];
+ 1];
uint64_t prof_interval = 0;
bool prof_promote;